s3 lifecycle updates (#75)
- Added `filter {}` to resource `aws_s3_bucket_lifecycle_configuration`
block(s)
- Added `filter = []` to `module.s3_bucket_for_logs in
addons/logging-alb/main.tf`
- Added `filter = []` to `module.athena-s3-bucket in
addons/logging-alb/main.tf`
---
Addresses the following warnings.
```
No attribute specified when one (and only one) of [rule[0].filter,rule[0].prefix] is required
```
---
```
╷
│ Warning: Invalid Attribute Combination
│
│ with module.logging_alb.module.athena-s3-bucket[0].aws_s3_bucket_lifecycle_configuration.this[0],
│ on .terraform/modules/logging_alb.athena-s3-bucket/main.tf line 219, in resource "aws_s3_bucket_lifecycle_configuration" "this":
│ 219: resource "aws_s3_bucket_lifecycle_configuration" "this" {
│
│ 2 attributes specified when one (and only one) of [rule[0].expiration[0].date,rule[0].expiration[0].days,rule[0].expiration[0].expired_object_delete_marker] is required
```
This commit is contained in:
1 parent
7d8311c83c
commit
c0d008bbf4
5 files changed
+9
-7
No files matched your search
@@ -168,13 +168,12 @@ module "s3_bucket_for_logs" {
|
||||
]
|
||||
expiration = {
|
||||
days = var.s3_expiration_days
|
||||
# Always resets to false anyhow showing terraform changes constantly
|
||||
expired_object_delete_marker = false
|
||||
}
|
||||
noncurrent_version_expiration = {
|
||||
newer_noncurrent_versions = var.s3_newer_noncurrent_versions
|
||||
days = var.s3_noncurrent_version_expiration_days
|
||||
}
|
||||
filter = []
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -226,13 +225,12 @@ module "athena-s3-bucket" {
|
||||
]
|
||||
expiration = {
|
||||
days = var.s3_expiration_days
|
||||
# Always resets to false anyhow showing terraform changes constantly
|
||||
expired_object_delete_marker = false
|
||||
}
|
||||
noncurrent_version_expiration = {
|
||||
newer_noncurrent_versions = var.s3_newer_noncurrent_versions
|
||||
days = var.s3_noncurrent_version_expiration_days
|
||||
}
|
||||
filter = []
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ resource "aws_s3_bucket_lifecycle_configuration" "osquery-results" {
|
||||
expiration {
|
||||
days = var.osquery_results_s3_bucket.expires_days
|
||||
}
|
||||
filter {}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,6 +60,7 @@ resource "aws_s3_bucket_lifecycle_configuration" "osquery-status" {
|
||||
expiration {
|
||||
days = var.osquery_status_s3_bucket.expires_days
|
||||
}
|
||||
filter {}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ resource "aws_s3_bucket_lifecycle_configuration" "main" {
|
||||
expiration {
|
||||
days = var.osquery_carve_s3_bucket.expires_days
|
||||
}
|
||||
filter {}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -319,6 +319,7 @@ resource "aws_s3_bucket_lifecycle_configuration" "software_installers" {
|
||||
noncurrent_days = 30
|
||||
}
|
||||
status = "Enabled"
|
||||
filter {}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -52,7 +52,7 @@ locals {
|
||||
}
|
||||
|
||||
module "fleet" {
|
||||
source = "github.com/fleetdm/fleet-terraform?depth=1&ref=tf-mod-root-v1.16.2"
|
||||
source = "github.com/fleetdm/fleet-terraform?depth=1&ref=tf-mod-root-v1.16.3"
|
||||
certificate_arn = module.acm.acm_certificate_arn
|
||||
|
||||
vpc = {
|
||||
@@ -143,7 +143,7 @@ module "migrations" {
|
||||
|
||||
# Enable if using s3 for carves
|
||||
# module "osquery-carve" {
|
||||
# source = "github.com/fleetdm/fleet-terraform/addons/osquery-carve?depth=1&ref=tf-mod-addon-osquery-carve-v1.1.0"
|
||||
# source = "github.com/fleetdm/fleet-terraform/addons/osquery-carve?depth=1&ref=tf-mod-addon-osquery-carve-v1.1.1"
|
||||
# osquery_carve_s3_bucket = {
|
||||
# name = local.osquery_carve_bucket_name
|
||||
# }
|
||||
@@ -151,7 +151,7 @@ module "migrations" {
|
||||
|
||||
# Uncomment if using firehose logging destination
|
||||
# module "firehose-logging" {
|
||||
# source = "github.com/fleetdm/fleet-terraform/addons/logging-destination-firehose?depth=1&ref=tf-mod-addon-logging-destination-firehose-v1.1.1"
|
||||
# source = "github.com/fleetdm/fleet-terraform/addons/logging-destination-firehose?depth=1&ref=tf-mod-addon-logging-destination-firehose-v1.2.1"
|
||||
# osquery_results_s3_bucket = {
|
||||
# name = local.osquery_results_bucket_name
|
||||
# }
|
||||
|
||||
Reference in new issue
Block a user