From dfcca146b8c6efdf9fb61904c24f01f1029cdd62 Mon Sep 17 00:00:00 2001 From: Maciej Matysiak <103054339+mmgovuk@users.noreply.github.com> Date: Tue, 21 Nov 2023 09:21:49 +0000 Subject: [PATCH 1/2] CC-2202: New volumes for EBS DB in Test and Pre-Production. --- .../environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf b/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf index de4380f191c..5425f079b40 100644 --- a/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf +++ b/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf @@ -262,7 +262,7 @@ resource "aws_volume_attachment" "diag_att" { } resource "aws_ebs_volume" "dbf01" { - count = local.is-development ? 1 : 0 + count = local.is-production ? 0 : 1 lifecycle { ignore_changes = [kms_key_id] } @@ -278,7 +278,7 @@ resource "aws_ebs_volume" "dbf01" { } resource "aws_volume_attachment" "dbf01_att" { - count = local.is-development ? 1 : 0 + count = local.is-production ? 0 : 1 depends_on = [ aws_ebs_volume.dbf01 ] @@ -289,7 +289,7 @@ resource "aws_volume_attachment" "dbf01_att" { resource "aws_ebs_volume" "dbf02" { - count = local.is-development ? 1 : 0 + count = local.is-production ? 0 : 1 lifecycle { ignore_changes = [kms_key_id] } @@ -305,7 +305,7 @@ resource "aws_ebs_volume" "dbf02" { } resource "aws_volume_attachment" "dbf02_att" { - count = local.is-development ? 1 : 0 + count = local.is-production ? 0 : 1 depends_on = [ aws_ebs_volume.dbf02 ] @@ -316,7 +316,7 @@ resource "aws_volume_attachment" "dbf02_att" { resource "aws_ebs_volume" "dbf03" { - count = local.is-development ? 1 : 0 + count = local.is-production ? 0 : 1 lifecycle { ignore_changes = [kms_key_id] } @@ -332,7 +332,7 @@ resource "aws_ebs_volume" "dbf03" { } resource "aws_volume_attachment" "dbf03_att" { - count = local.is-development ? 1 : 0 + count = local.is-production ? 0 : 1 depends_on = [ aws_ebs_volume.dbf03 ] From f630809bb385a0a5cd9fcb5e7d2c3a0f4b1caf3b Mon Sep 17 00:00:00 2001 From: Maciej Matysiak <103054339+mmgovuk@users.noreply.github.com> Date: Mon, 27 Nov 2023 15:59:03 +0000 Subject: [PATCH 2/2] CC-2202: Added the ebs_iops_ebsdb_dbf0x parameter. --- .../ccms-ebs/application_variables.json | 14 +++++++++++++- .../ccms-ebs/ccms-ec2-oracle_ebs_db.tf | 6 +++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/terraform/environments/ccms-ebs/application_variables.json b/terraform/environments/ccms-ebs/application_variables.json index c5b04b67b3b..c792bce3466 100644 --- a/terraform/environments/ccms-ebs/application_variables.json +++ b/terraform/environments/ccms-ebs/application_variables.json @@ -69,8 +69,11 @@ "ebs_size_ebsdb_u01": 300, "ebs_size_ebsdb_arch": 500, "ebs_size_ebsdb_dbf": 11000, + "ebs_iops_ebsdb_dbf01": 12000, "ebs_size_ebsdb_dbf01": 4000, + "ebs_iops_ebsdb_dbf02": 12000, "ebs_size_ebsdb_dbf02": 4000, + "ebs_iops_ebsdb_dbf03": 12000, "ebs_size_ebsdb_dbf03": 3000, "ebs_size_ebsdb_dbf_dr": 8000, "ebs_size_ebsdb_redoA": 100, @@ -150,8 +153,11 @@ "ebs_size_ebsdb_u01": 300, "ebs_size_ebsdb_arch": 500, "ebs_size_ebsdb_dbf": 11000, + "ebs_iops_ebsdb_dbf01": 12000, "ebs_size_ebsdb_dbf01": 4000, + "ebs_iops_ebsdb_dbf02": 12000, "ebs_size_ebsdb_dbf02": 4000, + "ebs_iops_ebsdb_dbf03": 12000, "ebs_size_ebsdb_dbf03": 3000, "ebs_size_ebsdb_redoA": 100, "ebs_size_ebsdb_redoB": 50, @@ -229,8 +235,11 @@ "ebs_size_ebsdb_u01": 300, "ebs_size_ebsdb_arch": 500, "ebs_size_ebsdb_dbf": 11000, + "ebs_iops_ebsdb_dbf01": 24000, "ebs_size_ebsdb_dbf01": 4000, - "ebs_size_ebsdb_dbf02": 4000, + "ebs_iops_ebsdb_dbf02": 24000, + "ebs_size_ebsdb_dbf02": 5000, + "ebs_iops_ebsdb_dbf03": 24000, "ebs_size_ebsdb_dbf03": 3000, "ebs_size_ebsdb_redoA": 100, "ebs_size_ebsdb_redoB": 50, @@ -308,8 +317,11 @@ "ebs_size_ebsdb_u01": 300, "ebs_size_ebsdb_arch": 500, "ebs_size_ebsdb_dbf": 11000, + "ebs_iops_ebsdb_dbf01": 24000, "ebs_size_ebsdb_dbf01": 4000, + "ebs_iops_ebsdb_dbf02": 24000, "ebs_size_ebsdb_dbf02": 4000, + "ebs_iops_ebsdb_dbf03": 24000, "ebs_size_ebsdb_dbf03": 3000, "ebs_size_ebsdb_redoA": 100, "ebs_size_ebsdb_redoB": 50, diff --git a/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf b/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf index 5425f079b40..3407776f45b 100644 --- a/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf +++ b/terraform/environments/ccms-ebs/ccms-ec2-oracle_ebs_db.tf @@ -269,7 +269,7 @@ resource "aws_ebs_volume" "dbf01" { availability_zone = "eu-west-2a" size = local.application_data.accounts[local.environment].ebs_size_ebsdb_dbf01 type = "io2" - iops = 12000 + iops = local.application_data.accounts[local.environment].ebs_iops_ebsdb_dbf01 encrypted = true kms_key_id = data.aws_kms_key.ebs_shared.key_id tags = merge(local.tags, @@ -296,7 +296,7 @@ resource "aws_ebs_volume" "dbf02" { availability_zone = "eu-west-2a" size = local.application_data.accounts[local.environment].ebs_size_ebsdb_dbf02 type = "io2" - iops = 12000 + iops = local.application_data.accounts[local.environment].ebs_iops_ebsdb_dbf02 encrypted = true kms_key_id = data.aws_kms_key.ebs_shared.key_id tags = merge(local.tags, @@ -323,7 +323,7 @@ resource "aws_ebs_volume" "dbf03" { availability_zone = "eu-west-2a" size = local.application_data.accounts[local.environment].ebs_size_ebsdb_dbf03 type = "io2" - iops = 12000 + iops = local.application_data.accounts[local.environment].ebs_iops_ebsdb_dbf03 encrypted = true kms_key_id = data.aws_kms_key.ebs_shared.key_id tags = merge(local.tags,