Skip to content

Commit

Permalink
fix: sql deletion protection (#183)
Browse files Browse the repository at this point in the history
  • Loading branch information
krtk6160 authored May 31, 2024
1 parent cb037c2 commit e57feff
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions modules/postgresql/gcp/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ resource "google_sql_database_instance" "instance" {
deletion_protection = !local.destroyable

settings {
tier = local.tier
availability_type = local.highly_available ? "REGIONAL" : "ZONAL"
tier = local.tier
availability_type = local.highly_available ? "REGIONAL" : "ZONAL"
deletion_protection_enabled = !local.destroyable

dynamic "database_flags" {
for_each = local.max_connections > 0 ? [local.max_connections] : []
Expand Down

0 comments on commit e57feff

Please sign in to comment.