Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a poka-yoke to prevent unintentional destroy #350

Closed
wants to merge 1 commit into from

Conversation

errm
Copy link
Member

@errm errm commented Oct 11, 2023

It's quite easy to make a config change that requires the cluster to be destroyed and recreated. This is usually not what you want since the state of the cluster will be lost.

This config will prevent terraform from trying to apply a change that requires the cluster to be destroyed ... if that is really what you wanted to do you must set prevent_destroy = false first

It's quite easy to make a config change that requires the cluster to
be destroyed and recreated.  This is usually not what you want
since the state of the cluster will be lost.

This config will prevent terraform from trying to apply a change
that requires the cluster to be destroyed ... if that is really
what you wanted to do you must set `prevent_destroy = false` first
@errm errm requested a review from a team as a code owner October 11, 2023 15:25
@errm
Copy link
Member Author

errm commented Oct 30, 2023

Currently there is no way to do this without hardcoding prevent_destroy = true inside the module...

This would also make the module untestable (at least with our current cleanup strategy).

@errm errm closed this Oct 30, 2023
@errm errm deleted the errm/prevent-destroy branch October 30, 2023 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant