Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removing tags and descriptions from secrets to prevent rds database from being destroyed/recreated #318

Merged
merged 2 commits into from
Sep 11, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 24 additions & 24 deletions secrets_manager.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ locals {
}

resource "aws_secretsmanager_secret" "moj_network_access_control_env_admin_db" {
name = "/moj-network-access-control/${terraform.workspace}/admin/db"
description = "Network Access Control - Admin RDS Database password."
provider = aws.env
tags = merge(local.tags_minus_name,
{ "Name" : "/moj-network-access-control/${terraform.workspace}/admin/db" }
)
name = "/moj-network-access-control/${terraform.workspace}/admin/db"
# description = "Network Access Control - Admin RDS Database password."
provider = aws.env
# tags = merge(local.tags_minus_name,
# { "Name" : "/moj-network-access-control/${terraform.workspace}/admin/db" }
# )
}

data "aws_secretsmanager_secret_version" "moj_network_access_control_env_admin_db" {
Expand Down Expand Up @@ -48,12 +48,12 @@ resource "random_password" "moj_network_access_control_env_admin_db" {
}

resource "aws_secretsmanager_secret" "moj_network_access_control_env_admin_sentry_dsn" {
name = "/moj-network-access-control/${terraform.workspace}/admin/sentry_dsn"
description = "Network Access Control - Sentry - Application monitoring and debugging software - Data Source Name (DSN)."
provider = aws.env
tags = merge(local.tags_minus_name,
{ "Name" : "/moj-network-access-control/${terraform.workspace}/admin/sentry_dsn" }
)
name = "/moj-network-access-control/${terraform.workspace}/admin/sentry_dsn"
# description = "Network Access Control - Sentry - Application monitoring and debugging software - Data Source Name (DSN)."
provider = aws.env
# tags = merge(local.tags_minus_name,
# { "Name" : "/moj-network-access-control/${terraform.workspace}/admin/sentry_dsn" }
# )
}

data "aws_secretsmanager_secret_version" "moj_network_access_control_env_admin_sentry_dsn" {
Expand All @@ -68,12 +68,12 @@ resource "aws_secretsmanager_secret_version" "moj_network_access_control_env_adm
}

resource "aws_secretsmanager_secret" "moj_network_access_control_env_eap_private_key_password" {
name = "/moj-network-access-control/${terraform.workspace}/eap/private_key_password"
description = "Network Access Control - Radius Extended Access Protocol (EAP) - private key password"
provider = aws.env
tags = merge(local.tags_minus_name,
{ "Name" : "/moj-network-access-control/${terraform.workspace}/eap/private_key_password" }
)
name = "/moj-network-access-control/${terraform.workspace}/eap/private_key_password"
# description = "Network Access Control - Radius Extended Access Protocol (EAP) - private key password"
provider = aws.env
# tags = merge(local.tags_minus_name,
# { "Name" : "/moj-network-access-control/${terraform.workspace}/eap/private_key_password" }
# )
}

data "aws_secretsmanager_secret_version" "moj_network_access_control_env_eap_private_key_password" {
Expand All @@ -88,12 +88,12 @@ resource "aws_secretsmanager_secret_version" "moj_network_access_control_env_eap
}

resource "aws_secretsmanager_secret" "moj_network_access_control_env_radsec_private_key_password" {
name = "/moj-network-access-control/${terraform.workspace}/radsec/private_key_password"
description = "Network Access Control - Radius RadSec TLS - private key password."
provider = aws.env
tags = merge(local.tags_minus_name,
{ "Name" : "/moj-network-access-control/${terraform.workspace}/radsec/private_key_password" }
)
name = "/moj-network-access-control/${terraform.workspace}/radsec/private_key_password"
# description = "Network Access Control - Radius RadSec TLS - private key password."
provider = aws.env
# tags = merge(local.tags_minus_name,
# { "Name" : "/moj-network-access-control/${terraform.workspace}/radsec/private_key_password" }
# )
}

data "aws_secretsmanager_secret_version" "moj_network_access_control_env_radsec_private_key_password" {
Expand Down