File tree Expand file tree Collapse file tree 3 files changed +7
-1
lines changed Expand file tree Collapse file tree 3 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ module "random_password" {
3838| create\_ secret | If false, this module does nothing (since tf doesn't support conditional modules) | ` bool ` | ` true ` | no |
3939| description | Description to add to Secret | ` string ` | ` "" ` | no |
4040| enable\_ secret\_ access\_ notification | Notify SNS topic on secret access (not recommended for most use cases) | ` bool ` | ` false ` | no |
41+ | kms\_ key\_ id | Optional. The KMS Key ID to encrypt the secret. KMS key arn or alias can be used. | ` any ` | ` null ` | no |
4142| length | Length of string | ` number ` | n/a | yes |
4243| min\_ lower | Minimum number of lower case characters | ` number ` | ` 0 ` | no |
4344| min\_ numeric | Minimum number of numbers | ` number ` | ` 0 ` | no |
Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ resource "aws_secretsmanager_secret" "secret" {
2727 name = var. name == " " ? null : var. name
2828 name_prefix = var. name == " " ? var. name_prefix : null
2929 description = var. description
30+ kms_key_id = var. kms_key_id
3031 tags = var. tags
3132}
3233
Original file line number Diff line number Diff line change @@ -13,6 +13,11 @@ variable "description" {
1313 type = string
1414}
1515
16+ variable "kms_key_id" {
17+ default = null
18+ description = " Optional. The KMS Key ID to encrypt the secret. KMS key arn or alias can be used."
19+ }
20+
1621variable "name" {
1722 default = " "
1823 description = " Name (omit to use name_prefix)"
@@ -72,7 +77,6 @@ variable "secret_access_notification_arn" {
7277variable "length" {
7378 description = " Length of string"
7479 type = number
75-
7680}
7781
7882variable "min_lower" {
You can’t perform that action at this time.
0 commit comments