pants icon indicating copy to clipboard operation
pants copied to clipboard

`experimental-destroy` for Terraform

Open d-m opened this issue 9 months ago • 1 comments

Is your feature request related to a problem? Please describe. It would be helpful if there was an experimental-destroy target to go along with experimental-deploy for the Terraform backend.

Describe the solution you'd like A clear and concise description of what you want to happen.

pants experimental-destroy would run terraform destroy

d-m avatar Apr 10 '25 18:04 d-m

I think this fits in with the idea that there are so many other parts of managing a deployment than really fit with pants's verbs. For example, with Terraform I frequently use import. I was thinking of 2 options (we could do both):

  1. making terraform_deployments a runnable target that fills in some of the other arguments. so pants run infra/deploy -- destroy
  2. making terraform_deployments exportable, so the providers would be written out and the backend initialised. I think this one is a bit fiddly, because you'd have to include the values in each invocation.

lilatomic avatar Apr 22 '25 01:04 lilatomic