Skip to content

Commit

Permalink
pull out tags and settings
Browse files Browse the repository at this point in the history
  • Loading branch information
badra001 committed Nov 17, 2021
1 parent 803de86 commit d330eaf
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 11 deletions.
6 changes: 6 additions & 0 deletions common/base_settings.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
locals {
account_id = data.aws_caller_identity.current.account_id
current_user_arn = data.aws_caller_identity.current.arn
partition = data.aws_arn.current.partition
region = data.aws_region.current.name
}
6 changes: 6 additions & 0 deletions common/base_tags.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
locals {
base_tags = {
"boc:tf_module_version" = local._module_version
"boc:created_by" = "terraform"
}
}
11 changes: 0 additions & 11 deletions common/resources.tf
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
locals {
account_id = data.aws_caller_identity.current.account_id
current_user_arn = data.aws_caller_identity.current.arn
partition = data.aws_arn.current.partition
region = data.aws_region.current.name
}

locals {
base_name = var.bucket_name
name = replace(var.bucket_name, local._prefixes["s3"], "")
Expand Down Expand Up @@ -34,10 +27,6 @@ locals {
# enforced_tags = {
# "boc:safeguard" = "title26"
# }
base_tags = {
"boc:tf_module_version" = local._module_version
"boc:created_by" = "terraform"
}
# strip spaces, convert to lowercase, make distinct, sort. Remove those not in the _defaults
add_safeguard_tags = local.enable_title26 ? ["title26"] : []
_default_safeguard_tags = { for d in local._defaults["data_safeguards"] : d => d }
Expand Down
1 change: 1 addition & 0 deletions kms_key/base_settings.tf
1 change: 1 addition & 0 deletions kms_key/base_tags.tf
1 change: 1 addition & 0 deletions standard/base_settings.tf
1 change: 1 addition & 0 deletions standard/base_tags.tf
1 change: 1 addition & 0 deletions title26/base_settings.tf
1 change: 1 addition & 0 deletions title26/base_tags.tf

0 comments on commit d330eaf

Please sign in to comment.