-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add expression to read environment variables #545
Comments
Interesting idea. Thanks for the suggestion! |
We've also considered adding envvar support to project defaults, see pulumi/pulumi#11547. If we added that it might be enough not not require support in the YAML language directly. |
For my understanding, does 'envvar support' mean reading from a .env file? Would this mean we'd need to do things like adding a step to inject secrets from environment into local files in the CI/CD job? If yes, I feel it's cleaner to directly access variables in the yaml. |
@jamest-pin I'm curious about your use case for injecting unique environment variables on subsequent executions. Is this something better served, perhaps, by automation API, deploying large numbers of similar stacks, or something else entirely? |
No. It means setting up something like:
The engine would fill in the "address" config value based on the value of the "TARGET_ADDRESS" envvar. So you'd need to set these config values in the Pulumi.yaml but you don't need extra .env files. |
Hello!
Issue details
Ability to access environment variables would be very handy. Would remove the need to have a wrapper script such as this
Thanks!
Affected area/feature
Pulumi yaml
The text was updated successfully, but these errors were encountered: