pulumi: Pulumi preview fails with permission errors for any stacks that use ESC environments
What happened?
Suddenly, as of today, any attempt to run even a pulumi preview on any of our stacks is failing with the following error:
error: getting stack configuration: opening environment: [0]
Diags: You do not have permission to perform this operation.
Judging by the error message’s mention of “environments”, I’m guessing maybe something changed with respect to the permission model for ESC environments? Because we do reference ESC environment(s) in our stack config files. But this was working as recently as a few days ago, and we haven’t changed anything. Did Pulumi change something around how these permissions work?
Example
Our stack config file looks more or less like this:
config:
key1: value1
environment:
- dev
and our ESC environment looks more or less like this:
values:
aws-region: us-east-1
global-secret:
fn::secret:
ciphertext: ZXN...abc123==
environmentVariables:
ESC_ENVIRONMENT_NAME: dev
pulumiConfig:
aws:region: "${aws-region}"
secrets:global: "${secret-abc}"
Output of pulumi about
Version 3.106.0
Go Version go1.22.0
Go Compiler gc
Plugins
NAME VERSION
nodejs unknown
Host
OS darwin
Version 14.3.1
Arch arm64
This project is written in nodejs: executable='/Users/daveh/n/bin/node' version='v18.14.2'
Current Stack: {org}/vpc-base/dev
TYPE URN
pulumi:pulumi:Stack urn:pulumi:dev::vpc-base::pulumi:pulumi:Stack::vpc-base-dev
pulumi:providers:pulumi urn:pulumi:dev::vpc-base::pulumi:providers:pulumi::default
...
Found no pending operations associated with {org}/dev
Backend
Name pulumi.com
URL https://app.pulumi.com/{user}
User {user}
Organizations {user}, {org}
Token type personal
Pulumi locates its logs in /var/folders/vw/2b3p74gx3s13s0bg7p9lg4kr0000gq/T/ by default
Additional context
We are on the Pulumi “Team Edition” plan.
pulumi preview seems to still work if performed by the organization admin user, but it fails for all of the other organization members. But we’ve used these features for months with all of our users, and have never had permissions issues until now.
This also breaks our Github actions integration, too… since it fails even just trying to run pulumi preview for pull requests.
Contributing
Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you’ve opened one already).
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 19 (11 by maintainers)
They are not, unfortunately. The default environment permission is the closest thing we have to a wildcard. Each environment must be added to the appropriate team(s) individually.
We’re actively planning a more flexible permission model. I’d definitely be interested to hear more about how you’d like to configure things in an ideal world and use that as input into our process.
No–it is set to
write.