Skip to content

variable "source_db" , for rds replica option #13

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
2 changes: 2 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ module "db_instance" {
port = "${var.port}"
iam_database_authentication_enabled = "${var.iam_database_authentication_enabled}"

replicate_source_db = "${var.replicate_source_db}"

vpc_security_group_ids = ["${var.vpc_security_group_ids}"]
db_subnet_group_name = "${module.db_subnet_group.this_db_subnet_group_id}"
parameter_group_name = "${module.db_parameter_group.this_db_parameter_group_id}"
Expand Down
2 changes: 2 additions & 0 deletions modules/db_instance/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ resource "aws_db_instance" "this" {
port = "${var.port}"
iam_database_authentication_enabled = "${var.iam_database_authentication_enabled}"

replicate_source_db = "${var.replicate_source_db}"

vpc_security_group_ids = ["${var.vpc_security_group_ids}"]
db_subnet_group_name = "${var.db_subnet_group_name}"
parameter_group_name = "${var.parameter_group_name}"
Expand Down
5 changes: 5 additions & 0 deletions modules/db_instance/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ variable "kms_key_id" {
default = ""
}

variable "replicate_source_db" {
description = "Specifies that this resource is a Replicate database, and to use this value as the source database. This correlates to the identifier of another Amazon RDS Database to replicate."
default = ""
}

variable "license_model" {
description = "License model information for this DB instance. Optional, but required for some DB engines, i.e. Oracle SE1"
default = ""
Expand Down
5 changes: 5 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ variable "kms_key_id" {
default = ""
}

variable "replicate_source_db" {
description = "Specifies that this resource is a Replicate database, and to use this value as the source database. This correlates to the identifier of another Amazon RDS Database to replicate."
default = ""
}

variable "license_model" {
description = "License model information for this DB instance. Optional, but required for some DB engines, i.e. Oracle SE1"
default = ""
Expand Down