How to prevent accidental deletion of a table or other stateful object? #797
Unanswered
jagoodhand
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Would be interested in any methods people have found for preventing the accidental deletion of an object.
Terraform by default has lifecycle, which prevents against the deletion of the object when
terraform destroy
is executed:Unfortunately, in the event that the code for that object is deleted, or commented out, then this setting will be removed and therefore the object destroyed. This makes it very easy for the commenting of some code, to cause a table (and all the information in it!) to be dropped.
There is an open issue with Terraform on how to address this, but I was wondering if the Snowflake community had come up with a solution specific to Snowflake to protect against this kind of thing?
Without this, I think I will need to use another method than Terraform to create the stateful resources, and limit Terraform to stateless resources that can easily be replaced in the event of accidental deletion.
Beta Was this translation helpful? Give feedback.
All reactions