mirror of
https://github.com/jlengrand/engine.git
synced 2026-03-10 08:11:21 +00:00
feat: adding rds disk encryption option
This commit is contained in:
committed by
Pierre Mavro
parent
b4402cf03b
commit
3e8c93e902
@@ -90,6 +90,7 @@ resource "aws_docdb_cluster" "documentdb_cluster" {
|
||||
master_username = var.username
|
||||
engine = "docdb"
|
||||
{%- endif %}
|
||||
storage_encrypted = var.encrypt_disk
|
||||
|
||||
# Network
|
||||
db_subnet_group_name = data.aws_subnet_ids.k8s_subnet_ids.id
|
||||
|
||||
@@ -34,4 +34,10 @@ variable "password" {
|
||||
description = "Admin password for the master DB user"
|
||||
default = "{{ database_password }}"
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "encrypt_disk" {
|
||||
description = "Enable disk encryption"
|
||||
default = "{{ encrypt_disk }}"
|
||||
type = string
|
||||
}
|
||||
@@ -87,6 +87,7 @@ resource "aws_db_instance" "mysql_instance" {
|
||||
password = var.password
|
||||
name = var.database_name
|
||||
parameter_group_name = aws_db_parameter_group.mysql_parameter_group.name
|
||||
storage_encrypted = var.encrypt_disk
|
||||
{%- if snapshot is defined and snapshot["snapshot_id"] %}
|
||||
# Snapshot
|
||||
snapshot_identifier = var.snapshot_identifier
|
||||
|
||||
@@ -36,6 +36,12 @@ variable "storage_type" {
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "encrypt_disk" {
|
||||
description = "Enable disk encryption"
|
||||
default = "{{ encrypt_disk }}"
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "instance_class" {
|
||||
description = "Type of instance: https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html"
|
||||
default = "{{database_instance_type}}"
|
||||
|
||||
@@ -73,6 +73,7 @@ resource "aws_db_instance" "postgresql_instance" {
|
||||
delete = "60m"
|
||||
}
|
||||
password = var.password
|
||||
storage_encrypted = var.encrypt_disk
|
||||
{%- if snapshot and snapshot["snapshot_id"] %}
|
||||
# Snapshot
|
||||
snapshot_identifier = var.snapshot_identifier
|
||||
|
||||
@@ -30,6 +30,12 @@ variable "storage_type" {
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "encrypt_disk" {
|
||||
description = "Enable disk encryption"
|
||||
default = "{{ encrypt_disk }}"
|
||||
type = string
|
||||
}
|
||||
|
||||
variable "instance_class" {
|
||||
description = "Type of instance: https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html"
|
||||
default = "{{ database_instance_type }}"
|
||||
|
||||
Reference in New Issue
Block a user