That’s a really good question 👀 I mean you could export the stack, cut the resource you want to preserve from the array, import the stack,
pulumi destroy
and then if wanted export the stack, paste the resource, import stack, done. Though if, as you say other resources depend on this certificate you can’t just cut the resource from the array but have to manually remove the id from the dependencies array of each resource
v
victorious-xylophone-55816
09/20/2020, 10:10 PM
Ahh I didn't know about the `export`/`import` thing, thank you! Though like you mentioned, it has a good number of dependencies so I think I'll just manually delete everything and abandon that stack for now haha
g
gentle-diamond-70147
09/21/2020, 3:29 PM
You can do a
destroy --target ...
to delete the resources you want to delete without touching the cert.
😍 1
b
billowy-kangaroo-51688
09/27/2020, 6:05 AM
😍 @gentle-diamond-70147 that’s super useful, didn’t know about it so far 🎉
No matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.