Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
terraform_aurora_postgresql [2023/09/10 15:03] – andonovj | terraform_aurora_postgresql [2023/09/10 15:05] (current) – andonovj | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | =====Overview===== | + | ======Overview====== |
In this module, we will configure Aurora PostrgreSQL with one node (reader and writer). Furthermore, | In this module, we will configure Aurora PostrgreSQL with one node (reader and writer). Furthermore, | ||
So let's get started. | So let's get started. | ||
- | =====Configure the publisher / provider ===== | + | ====== Configure the publisher / provider |
Firstly, we will start with the creation of the Aurora PostgreSQL, which will acts as a Publisher / Provider | Firstly, we will start with the creation of the Aurora PostgreSQL, which will acts as a Publisher / Provider | ||
Line 370: | Line 370: | ||
- | ===== Configure the Subscriber ===== | + | ====== Configure the Subscriber |
The following code, will configure RDS PostgreSQL and it will create some Demo structure for the pg_logical: | The following code, will configure RDS PostgreSQL and it will create some Demo structure for the pg_logical: | ||
Line 611: | Line 611: | ||
</ | </ | ||
+ | Of course, that excludes all the meta configuration which you need to do for Terraform like: " | ||
+ | That being said, as we need the security rules (ports, etc), here is extract from vars: | ||
+ | |||
+ | |||
+ | < | ||
+ | variable " | ||
+ | description = " | ||
+ | type = string | ||
+ | default | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "Name of the environment" | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "The password for the database" | ||
+ | type = string | ||
+ | |||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "The username for the database" | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "The path of the private key" | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = " | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "AMI for the EC2 image" | ||
+ | type = string | ||
+ | default | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "The path for the configuration of the source cluster" | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "The name of the virtual database we will replicate" | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | variable " | ||
+ | description = "The endpoint of the source database, provided manually for now" | ||
+ | type = string | ||
+ | } | ||
+ | |||
+ | |||
+ | variable " | ||
+ | type = list(object({ | ||
+ | from_port | ||
+ | to_port | ||
+ | protocol | ||
+ | description = string | ||
+ | })) | ||
+ | default = [ | ||
+ | { | ||
+ | from_port | ||
+ | to_port | ||
+ | protocol | ||
+ | description = "ssh access" | ||
+ | }, | ||
+ | { | ||
+ | from_port | ||
+ | to_port | ||
+ | protocol | ||
+ | description = " | ||
+ | }, | ||
+ | ] | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | The " |