Skip to content

Commit

Permalink
fix(aws-mongodbatlas-cluster): added default value for map lookup in…
Browse files Browse the repository at this point in the history
… aws_kms_config (#220)
  • Loading branch information
akcinardoga authored May 16, 2024
1 parent 493b3d8 commit ad2e473
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/aws-mongodbatlas-cluster/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,9 @@ resource "mongodbatlas_encryption_at_rest" "aws_encryption" {

aws_kms_config {
enabled = true
customer_master_key_id = coalesce(lookup(var.aws_kms_config, "customer_master_key_id"), var.kms_customer_master_key_id)
region = coalesce(lookup(var.aws_kms_config, "region"), var.kms_region)
role_id = coalesce(lookup(var.aws_kms_config, "atlas_role_id"), var.atlas_role_id)
customer_master_key_id = coalesce(lookup(var.aws_kms_config, "customer_master_key_id", null), var.kms_customer_master_key_id)
region = coalesce(lookup(var.aws_kms_config, "region", null), var.kms_region)
role_id = coalesce(lookup(var.aws_kms_config, "atlas_role_id", null), var.atlas_role_id)
}
}

Expand Down

0 comments on commit ad2e473

Please sign in to comment.