Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ resource "aws_rds_cluster" "this" {
manage_master_user_password = var.global_cluster_identifier == null && var.manage_master_user_password ? var.manage_master_user_password : null
master_user_secret_kms_key_id = var.global_cluster_identifier == null && var.manage_master_user_password ? var.master_user_secret_kms_key_id : null
master_password = var.is_primary_cluster && !var.manage_master_user_password ? var.master_password : null
master_password_wo = var.master_password_wo
master_password_wo_version = var.master_password_wo_version
master_username = var.is_primary_cluster ? var.master_username : null
monitoring_interval = var.cluster_monitoring_interval
monitoring_role_arn = var.create_monitoring_role && var.cluster_monitoring_interval > 0 ? try(aws_iam_role.rds_enhanced_monitoring[0].arn, null) : var.monitoring_role_arn
Expand Down
14 changes: 14 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,20 @@ variable "master_password" {
default = null
}

variable "master_password_wo" {
description = "Write-only password for the master DB user. Required unless `manage_master_user_password` is set to `true`, or unless `snapshot_identifier` or `replication_source_identifier` is provided, or unless a `global_cluster_identifier` is provided when the cluster is the secondary cluster of a global database. Unlike `master_password`, this value will not be stored in the Terraform state file"
type = string
ephemeral = true
default = null
}

variable "master_password_wo_version" {
description = "Optional version identifier used to detect changes in `master_password_wo` and force update. Increment to rotate the password."
type = string
default = null
}


variable "master_username" {
description = "Username for the master DB user. Required unless `snapshot_identifier` or `replication_source_identifier` is provided or unless a `global_cluster_identifier` is provided when the cluster is the secondary cluster of a global database"
type = string
Expand Down
Loading