Skip to content

Commit 179eeb9

Browse files
committed
NRL-853 split back into different plans for s3 and ddb
1 parent 1d715a2 commit 179eeb9

File tree

2 files changed

+2
-88
lines changed

2 files changed

+2
-88
lines changed

terraform/account-wide-infrastructure/modules/backup-source/backup_plan.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,6 @@ resource "aws_backup_selection" "dynamodb" {
8080
selection_tag {
8181
key = var.backup_plan_config_dynamodb.selection_tag
8282
type = "STRINGEQUALS"
83-
value = "True"
83+
value = "true"
8484
}
8585
}

terraform/account-wide-infrastructure/modules/backup-source/variables.tf

Lines changed: 1 addition & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -89,56 +89,7 @@ variable "backup_plan_config" {
8989
}))
9090
}))
9191
})
92-
default = {
93-
selection_tag = "BackupLocal"
94-
compliance_resource_types = ["S3"]
95-
rules = [
96-
{
97-
name = "daily_kept_5_weeks"
98-
schedule = "cron(0 0 * * ? *)"
99-
lifecycle = {
100-
delete_after = 35
101-
}
102-
copy_action = {
103-
delete_after = 365
104-
}
105-
},
106-
{
107-
name = "weekly_kept_3_months"
108-
schedule = "cron(0 1 ? * SUN *)"
109-
lifecycle = {
110-
delete_after = 90
111-
}
112-
copy_action = {
113-
delete_after = 365
114-
}
115-
},
116-
{
117-
name = "monthly_kept_7_years"
118-
schedule = "cron(0 2 1 * ? *)"
119-
lifecycle = {
120-
cold_storage_after = 30
121-
delete_after = 2555
122-
}
123-
copy_action = {
124-
delete_after = 365
125-
}
126-
},
127-
{
128-
name = "point_in_time_recovery"
129-
schedule = "cron(0 5 * * ? *)"
130-
enable_continuous_backup = true
131-
lifecycle = {
132-
delete_after = 35
133-
}
134-
copy_action = {
135-
delete_after = 365
136-
}
137-
}
138-
]
139-
}
14092
}
141-
14293
variable "backup_plan_config_dynamodb" {
14394
description = "Configuration for backup plans with dynamodb"
14495
type = object({
@@ -158,42 +109,5 @@ variable "backup_plan_config_dynamodb" {
158109
}))
159110
})))
160111
})
161-
default = {
162-
enable = true
163-
selection_tag = "BackupDynamoDB"
164-
compliance_resource_types = ["DynamoDB"]
165-
rules = [
166-
{
167-
name = "dynamodb_daily_kept_5_weeks"
168-
schedule = "cron(0 0 * * ? *)"
169-
lifecycle = {
170-
delete_after = 35
171-
}
172-
copy_action = {
173-
delete_after = 365
174-
}
175-
},
176-
{
177-
name = "dynamodb_weekly_kept_3_months"
178-
schedule = "cron(0 1 ? * SUN *)"
179-
lifecycle = {
180-
delete_after = 90
181-
}
182-
copy_action = {
183-
delete_after = 365
184-
}
185-
},
186-
{
187-
name = "dynamodb_monthly_kept_7_years"
188-
schedule = "cron(0 2 1 * ? *)"
189-
lifecycle = {
190-
cold_storage_after = 30
191-
delete_after = 2555
192-
}
193-
copy_action = {
194-
delete_after = 365
195-
}
196-
}
197-
]
198-
}
112+
199113
}

0 commit comments

Comments
 (0)