Skip to content

Commit 8ed98b1

Browse files
fix db password special char
1 parent b60f142 commit 8ed98b1

2 files changed

Lines changed: 6 additions & 5 deletions

File tree

modules/datastore/postgres/gcp-cloudsql/1.0/facets.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
intent: postgres
22
flavor: gcp-cloudsql
3-
version: '1.0'
3+
version: '2.0'
44
clouds:
55
- gcp
66
description: Managed PostgreSQL database using Google Cloud SQL with secure defaults
@@ -252,7 +252,7 @@ iac:
252252
sample:
253253
kind: postgres
254254
flavor: gcp-cloudsql
255-
version: '1.0'
255+
version: '2.0'
256256
disabled: true
257257
spec:
258258
version_config:

modules/datastore/postgres/gcp-cloudsql/1.0/main.tf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44

55
# Random password for PostgreSQL user (when not restoring from backup or importing)
66
resource "random_password" "postgres_password" {
7-
count = var.instance.spec.restore_config.restore_from_backup ? 0 : 1
8-
length = 16
9-
special = true
7+
count = var.instance.spec.restore_config.restore_from_backup ? 0 : 1
8+
length = 16
9+
special = true
10+
override_special = "!#$&*-=?^_`{|}~" # Safe special characters, excludes ;+% rejected by AWS DMS
1011

1112
lifecycle {
1213
ignore_changes = [

0 commit comments

Comments
 (0)