From e144c970276af2201a7e84accf36bf8aebc58c84 Mon Sep 17 00:00:00 2001 From: Hoang Mirs Date: Fri, 30 Dec 2022 14:53:13 +0700 Subject: [PATCH] [#148] Fix: Wrong database_url string in SSM module --- src/templates/aws/addons/ssm.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/templates/aws/addons/ssm.ts b/src/templates/aws/addons/ssm.ts index 72f27a96..54f8390c 100644 --- a/src/templates/aws/addons/ssm.ts +++ b/src/templates/aws/addons/ssm.ts @@ -9,6 +9,10 @@ const ssmVariablesContent = dedent` type = string } \n`; +/* eslint-disable no-template-curly-in-string */ +const databaseUrlString = + 'postgres://${var.rds_username}:${var.rds_password}@${module.rds.db_endpoint}/${var.rds_database_name}'; +/* eslint-enable no-template-curly-in-string */ const ssmModuleContent = dedent` module "ssm" { source = "./modules/ssm" @@ -16,7 +20,7 @@ const ssmModuleContent = dedent` namespace = var.namespace secrets = { - database_url = "postgres://\${var.rds_username}:\${var.rds_password}@\${module.rds.db_endpoint}/\${var.rds_database_name}" + database_url = "${databaseUrlString}" secret_key_base = var.secret_key_base } }