Skip to content

Change google_compute_instance deletion_protection default to true #15368

Open
@rileykarson

Description

@rileykarson

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment. If the issue is assigned to the "modular-magician" user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If the issue is assigned to a user, that user is claiming responsibility for the issue. If the issue is assigned to "hashibot", a community member has claimed the issue already.

Description

Note: I'm filing this, but I'm not entirely sure we should do it- a GCE instance is not always storing data that will be lost on accidental deletion, much less than a database product or even a GKE cluster.

This was added in #1205, and maps to https://cloud.google.com/compute/docs/instances/preventing-accidental-vm-deletion. Every other deletion_protection field I'm aware of started as a client-only field that defaults to true, starting with google_bigtable_instance and proliferating across other databases. We may want to consider making it consistent with that practice.

New or Affected Resource(s)

  • google_compute_instance

Potential Terraform Configuration

# Propose what you think the configuration to take advantage of this feature should look like.
# We may not use it verbatim, but it's helpful in understanding your intent.

References

  • #0000

b/312433119

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions