From 09626d49b239a0e84f71e576a2e843e3867c6e47 Mon Sep 17 00:00:00 2001 From: Pascual Camacho <82928224+pascualcam@users.noreply.github.com> Date: Wed, 3 Sep 2025 10:34:27 -0700 Subject: [PATCH] add rds backup retention period --- modules/aws_ecs/main.tf | 1 + modules/aws_ecs/variables.tf | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/modules/aws_ecs/main.tf b/modules/aws_ecs/main.tf index b89b2a7..c14c315 100644 --- a/modules/aws_ecs/main.tf +++ b/modules/aws_ecs/main.tf @@ -42,6 +42,7 @@ resource "aws_db_instance" "this" { storage_throughput = var.rds_storage_throughput iops = var.rds_iops multi_az = var.rds_multi_az + backup_retention_period = var.backup_retention_period skip_final_snapshot = true apply_immediately = true diff --git a/modules/aws_ecs/variables.tf b/modules/aws_ecs/variables.tf index 81651d9..7c5a288 100644 --- a/modules/aws_ecs/variables.tf +++ b/modules/aws_ecs/variables.tf @@ -348,6 +348,12 @@ variable "temporal_aurora_backup_retention_period" { description = "Number of days to retain backups for Temporal Aurora. Defaults to 7." } +variable "backup_retention_period" { + type = number + default = 7 + description = "Number of days to retain backups for RDS instance. Defaults to 7." +} + variable "temporal_aurora_preferred_backup_window" { type = string default = "03:00-04:00"