Skip to content

Commit 89e39ae

Browse files
committed
CCM-11352: add flag to force destory bucket if enabled
1 parent e09d25c commit 89e39ae

3 files changed

Lines changed: 8 additions & 1 deletion

File tree

infrastructure/modules/eventpub/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
| <a name="input_environment"></a> [environment](#input\_environment) | The name of the terraformscaffold environment the module is called for | `string` | n/a | yes |
2323
| <a name="input_event_cache_buffer_interval"></a> [event\_cache\_buffer\_interval](#input\_event\_cache\_buffer\_interval) | The buffer interval for data firehose | `number` | `500` | no |
2424
| <a name="input_event_cache_expiry_days"></a> [event\_cache\_expiry\_days](#input\_event\_cache\_expiry\_days) | s3 archiving expiry in days | `number` | `30` | no |
25+
| <a name="input_force_destroy_event_cache_bucket"></a> [force\_destroy\_event\_cache\_bucket](#input\_force\_destroy\_event\_cache\_bucket) | When enabled will force destroy event-cache S3 bucket | `bool` | `false` | no |
2526
| <a name="input_group"></a> [group](#input\_group) | The name of the tfscaffold group | `string` | `null` | no |
2627
| <a name="input_iam_permissions_boundary_arn"></a> [iam\_permissions\_boundary\_arn](#input\_iam\_permissions\_boundary\_arn) | The ARN of the permissions boundary to use for the IAM role | `string` | `null` | no |
2728
| <a name="input_kms_key_arn"></a> [kms\_key\_arn](#input\_kms\_key\_arn) | KMS key arn to use for this function | `string` | n/a | yes |

infrastructure/modules/eventpub/module_s3bucket_event_cache.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ module "s3bucket_event_cache" {
1212
component = var.component
1313

1414
acl = "private"
15-
force_destroy = false
15+
force_destroy = var.force_destroy_event_cache_bucket
1616
versioning = true
1717

1818
lifecycle_rules = [

infrastructure/modules/eventpub/variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,3 +118,9 @@ variable "iam_permissions_boundary_arn" {
118118
description = "The ARN of the permissions boundary to use for the IAM role"
119119
default = null
120120
}
121+
122+
variable "force_destroy_event_cache_bucket" {
123+
type = bool
124+
description = "When enabled will force destroy event-cache S3 bucket"
125+
default = false
126+
}

0 commit comments

Comments
 (0)