diff --git a/README.md b/README.md index 97ba6c7..ce7dc1d 100644 --- a/README.md +++ b/README.md @@ -14,11 +14,6 @@ module "secretsmanager-for-rollbar-access-tokens" { name_prefix = "example" rollbar_tokens = values(rollbar_project_access_token.example) - - tags = { - app = "example" - env = "production" - } } ``` diff --git a/_test/main.tf b/_test/main.tf index 9991321..eaf098f 100644 --- a/_test/main.tf +++ b/_test/main.tf @@ -22,7 +22,7 @@ module "secretsmanager" { rollbar_tokens = local.rollbar_tokens - tags = { + default_tags = { app = "example" env = "production" } diff --git a/main.tf b/main.tf index 7a77a95..266fac1 100644 --- a/main.tf +++ b/main.tf @@ -2,7 +2,7 @@ resource "aws_secretsmanager_secret" "this" { name = "${var.name_prefix}.rollbar_access_tokens" description = "Secret value is managed via Terraform" - tags = var.tags + tags = var.default_tags } resource "aws_secretsmanager_secret_version" "this" { diff --git a/variables.tf b/variables.tf index 7b366ee..6658c4e 100644 --- a/variables.tf +++ b/variables.tf @@ -1,3 +1,12 @@ +variable "default_tags" { + type = map(string) + default = {} + + description = <