This message was deleted.
# general
s
This message was deleted.
g
There isn't a command to do that, but you can remove the resource from Pulumi's stack using
pulumi state rm ...
. That will leave the resource "orphaned", so you'll need to delete it manually if you still need to.
l
Another possibility is to comment everything else out temporarily, and use
pulumi up
to destroy them.
m
gotcha
so perhaps I’m thinking of these particular resources in the wrong way. The first is:
new gcp.projects.Service("EnableCloudRun", { service: "<http://run.googleapis.com|run.googleapis.com>" }, { protect: true });
which is essentially just a flag that I need to enable one time. We’d like to enable it programmatically, so we do there, and it doesn’t seem to cause any problems when running it on multiple stacks in the same project. But if I try to destroy the stack, or comment out the line, then pulumi tries to delete it. So what’s the recommended approach for saying “hey turn this thing on” but don’t try to delete it?
a similar one is
new gcp.appengine.Application
g
There isn't a feature that does what you're asking. I think the best way to address it would be to have those items in their own project/stack that you run before your other stacks that rely on them.
m
okay
you both have been very helpful, thank you. I think I’m getting a better handle on some of the stack state management that I’ve been having issues with. We’ve done some cool stuff with pulumi + gcp over the last few weeks, but some things have left me scratching my head, and you’ve helped me get a better understanding of those things
👍 1