Question about dynamic config in Pulumi: We have ...
# general
b
Question about dynamic config in Pulumi: We have deployment pipelines which, on merge, build a new version of our app tagged with the commit sha and then deploy it via Pulumi. As such, we don't set
app:version
in our committed config files, the deployment pipeline just uses
pulumi up --config app:version=${COMMIT_SHA}
. This works fine. You can also preview the potential changes in the same way via
pulumi preview
. However, a lot of other commands we might want to run, which would normally be manual for when things have gone wrong rather than driven by CI, both • Require all config variables to be specified. • Don't accept
--config
as a valid CLI parameter. e.g.
Copy code
$ pulumi destroy
error: validating stack config: Stack 'test-uk1' is missing configuration value 'app:version'

$ pulumi destroy --config app:version=foo
error: unknown flag: --config
So you end up having to set a 'dummy' value in the configuration file temporarily to be able to run those commands. The same seems to be true for
pulumi refresh
, for example. Is there any way around this? Should I raise a ticket about it? It feels like
--config
should be a globally-valid parameter for any pulumi action which requires the config to be present (e.g.
pulumi state export
doesn't actually care that the config is not complete as it's not attempting to run the app at all)
e
Raise an issue, I agree it sounds like this should probably just be exposed on all commands that use the config system
b