Hi pulumi, I'd like to know is it possible to `pro...
# general
Hi pulumi, I'd like to know is it possible to
a resource without having to run
pulumi up
? i.e. to add the
protect: true
to something directly. More context on why in the thread:
So I previously had a thread on a problem where
pulumi preview
is showing that changes will happen, without me having changed anything. https://pulumi-community.slack.com/archives/C84L4E3N1/p1570135724281600
This led to filing of an issue https://github.com/pulumi/pulumi/issues/3301
And there does seem to be a PR out that may address the issue, at https://github.com/pulumi/pulumi/pull/3327
Basically there's a stack that I can't
pulumi up
because of the risk that it'll destroy everything. But I want to add new resources to the stack. Maybe I can do this by manually adding
protect: true
to all the resources at risk of being recreated, before doing
pulumi up
. Would that work?
You can
pulumi stack export
, then add the protect:true, then
pulumi stack import
. We don’t yet have a direct command to do this in one set, but we do have a command for the opposite -
pulumi state unprotected <urn>
, which we should probably expand to support this scenario as well.
Thanks, I'll try