variable "name" { description = "The secret's name, such as app/api-token." type = string } variable "reader_role_arns" { description = "Roles allowed to read the secret. Everyone else is refused, administrators included. Remove a role here to take its access away." type = list(string) validation { condition = length(var.reader_role_arns) > 0 && alltrue([for a in var.reader_role_arns : can(regex("^arn:aws[a-z-]*:iam::[0-9]{12}:role/", a))]) error_message = "List at least one role ARN, with no wildcards." } } variable "rotation_days" { description = "Days between rotations." type = number default = 30 validation { condition = var.rotation_days >= 1 && var.rotation_days <= 1000 error_message = "Secrets Manager accepts 1 to 1000 days between rotations." } } variable "trail_log_group" { description = "CloudWatch log group a CloudTrail trail delivers to, for the alerts." type = string } variable "alert_topic_arn" { description = "SNS topic for the alerts." type = string } variable "owner" { description = "Tag contract: accountable team." type = string default = "platform-engineering" } variable "environment" { description = "Tag contract: environment." type = string default = "prod" } variable "extra_tags" { description = "Additional tags merged over the contract." type = map(string) default = {} }