diff --git a/terraform/environments/cdpt-ifs/database.tf b/terraform/environments/cdpt-ifs/database.tf index 8a9b1b47eff..3d2c8810a22 100644 --- a/terraform/environments/cdpt-ifs/database.tf +++ b/terraform/environments/cdpt-ifs/database.tf @@ -10,7 +10,7 @@ resource "aws_db_instance" "database" { instance_class = local.application_data.accounts[local.environment].db_instance_class identifier = local.application_data.accounts[local.environment].db_instance_identifier username = local.application_data.accounts[local.environment].db_user - password = aws_secretsmanager_secret_version.db_password.secret_string + password = aws_secretsmanager_secret_version.dbase_password.secret_string vpc_security_group_ids = [aws_security_group.db.id] depends_on = [aws_security_group.db] snapshot_identifier = local.application_data.accounts[local.environment].db_snapshot_identifier diff --git a/terraform/environments/cdpt-ifs/ecs.tf b/terraform/environments/cdpt-ifs/ecs.tf index 252da8342ea..d2f4bc1d90c 100644 --- a/terraform/environments/cdpt-ifs/ecs.tf +++ b/terraform/environments/cdpt-ifs/ecs.tf @@ -133,7 +133,7 @@ resource "aws_ecs_task_definition" "ifs_task_definition" { secrets = [ { name : "RDS_PASSWORD", - valueFrom : aws_secretsmanager_secret_version.db_password.arn + valueFrom : aws_secretsmanager_secret_version.dbase_password.arn } ], } diff --git a/terraform/environments/cdpt-ifs/secrets.tf b/terraform/environments/cdpt-ifs/secrets.tf index 0e22ff06e85..f49bdec9fe6 100644 --- a/terraform/environments/cdpt-ifs/secrets.tf +++ b/terraform/environments/cdpt-ifs/secrets.tf @@ -1,5 +1,5 @@ -resource "aws_secretsmanager_secret" "db_password" { - name = "database_password" +resource "aws_secretsmanager_secret" "dbase_password" { + name = "dbase_password" } resource "random_password" "password_long" { @@ -7,7 +7,7 @@ resource "random_password" "password_long" { special = false } -resource "aws_secretsmanager_secret_version" "db_password" { - secret_id = aws_secretsmanager_secret.db_password.id +resource "aws_secretsmanager_secret_version" "dbase_password" { + secret_id = aws_secretsmanager_secret.dbase_password.id secret_string = random_password.password_long.result }