Skip to content

Commit

Permalink
fix: acl not required with bucket ownership controls (#570)
Browse files Browse the repository at this point in the history
  • Loading branch information
bryan-robitaille authored Jan 10, 2024
1 parent 1d6273c commit 1e31ae7
Showing 1 changed file with 0 additions and 29 deletions.
29 changes: 0 additions & 29 deletions aws/s3/s3.tf
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,6 @@ resource "aws_s3_bucket_ownership_controls" "reliability_file_storage" {
}
}

resource "aws_s3_bucket_acl" "reliability_file_storage" {
depends_on = [aws_s3_bucket_ownership_controls.reliability_file_storage]
bucket = aws_s3_bucket.reliability_file_storage.id

acl = "private"
}

resource "aws_s3_bucket_lifecycle_configuration" "reliability_file_storage" {
# checkov:skip=CKV_AWS_300: Lifecycle configuration for aborting failed (multipart) upload not required
bucket = aws_s3_bucket.reliability_file_storage.id
Expand Down Expand Up @@ -76,14 +69,6 @@ resource "aws_s3_bucket_ownership_controls" "vault_file_storage" {
}
}

resource "aws_s3_bucket_acl" "vault_file_storage" {
depends_on = [aws_s3_bucket_ownership_controls.vault_file_storage]
bucket = aws_s3_bucket.vault_file_storage.id

acl = "private"
}


resource "aws_s3_bucket_server_side_encryption_configuration" "vault_file_storage" {
bucket = aws_s3_bucket.vault_file_storage.id

Expand Down Expand Up @@ -121,13 +106,6 @@ resource "aws_s3_bucket_ownership_controls" "archive_storage" {
}
}

resource "aws_s3_bucket_acl" "archive_storage" {
depends_on = [aws_s3_bucket_ownership_controls.archive_storage]
bucket = aws_s3_bucket.archive_storage.id

acl = "private"
}

resource "aws_s3_bucket_server_side_encryption_configuration" "archive_storage" {
bucket = aws_s3_bucket.archive_storage.id

Expand Down Expand Up @@ -177,13 +155,6 @@ resource "aws_s3_bucket_ownership_controls" "lambda_code" {
}
}

resource "aws_s3_bucket_acl" "lambda_code" {
depends_on = [aws_s3_bucket_ownership_controls.lambda_code]
bucket = aws_s3_bucket.lambda_code.id

acl = "private"
}

resource "aws_s3_bucket_versioning" "lambda_code" {
bucket = aws_s3_bucket.lambda_code.id
versioning_configuration {
Expand Down

0 comments on commit 1e31ae7

Please sign in to comment.