Hi, I am using pulumi to deploy my dev k3s cluster...
# getting-started
p
Hi, I am using pulumi to deploy my dev k3s clusters on a single VM, and after cluster provisioning I am applying some k8s manifests to create namespaces, deploy dev helm charts and e.t.c. and it works perfectly but when I do
pulumi down
I have to wait until all k8s resources will be deleted however it’d be enough to just delete compute instance with k3s cluster. Is there any way to implement such logic with pulumi?
s
You could set
retainOnDelete
on everything except the VM. You could also could set
skipAwait
on your K8s resources (I think?).
You could also try putting the VM and K8s resources in a separate stack and just tear down the VM stack, but that's pretty dirty and I'm not sure what experience you'd have trying to remove the K8s stack after the fact.
And I think you can set
retainOnDelete
conditionally based on the stack (it would be
true
in dev,
false
otherwise)
p
Thanks a lot! It seems that
retainOnDelete
is what I need.
youre welcome 1