Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: apply all PublicAccessBlockConfiguration for all s3 buckets #5130

Merged
merged 2 commits into from
Jul 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions e2e/multi-pipeline/s3template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true

e2epipelineaddonBucketPolicy:
Metadata:
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/addon/testdata/merge/env/second.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true

MyBucketAccessPolicy:
Type: AWS::IAM::ManagedPolicy
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/addon/testdata/merge/env/wanted.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
MyBucketAccessPolicy:
Type: AWS::IAM::ManagedPolicy
Properties:
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/addon/testdata/merge/second.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true

MyBucketAccessPolicy:
Type: AWS::IAM::ManagedPolicy
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/addon/testdata/merge/wanted.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
MyBucketAccessPolicy:
Type: AWS::IAM::ManagedPolicy
Properties:
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/addon/testdata/storage/bucket.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
OwnershipControls:
Rules:
- ObjectOwnership: BucketOwnerEnforced
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,11 @@ Resources:
ServerSideEncryptionConfiguration:
- ServerSideEncryptionByDefault:
SSEAlgorithm: AES256
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
ELBAccessLogsBucketPolicy:
Type: AWS::S3::BucketPolicy
Condition: CreateALB
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
OwnershipControls:
Rules:
- ObjectOwnership: BucketOwnerEnforced
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/template/templates/addons/s3/cf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
OwnershipControls:
Rules:
- ObjectOwnership: BucketOwnerEnforced
Expand Down
2 changes: 2 additions & 0 deletions internal/pkg/template/templates/addons/s3/env/cf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
OwnershipControls:
Rules:
- ObjectOwnership: BucketOwnerEnforced
Expand Down
5 changes: 5 additions & 0 deletions internal/pkg/template/templates/app/cf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,11 @@ Resources:
ServerSideEncryptionConfiguration:
- ServerSideEncryptionByDefault:
SSEAlgorithm: AES256
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
OwnershipControls:
Rules:
- ObjectOwnership: BucketOwnerEnforced
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,9 @@ ELBAccessLogsBucket:
BucketEncryption:
ServerSideEncryptionConfiguration:
- ServerSideEncryptionByDefault:
SSEAlgorithm: AES256
SSEAlgorithm: AES256
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
5 changes: 5 additions & 0 deletions internal/pkg/template/templates/task/cf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,11 @@ Resources:
ServerSideEncryptionConfiguration:
- ServerSideEncryptionByDefault:
SSEAlgorithm: AES256
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
LifecycleConfiguration:
Rules:
# .env files are only needed on the initial RunTask call and are not needed after that.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ Resources:
PublicAccessBlockConfiguration:
BlockPublicAcls: true
BlockPublicPolicy: true
IgnorePublicAcls: true
RestrictPublicBuckets: true
OwnershipControls:
Rules:
- ObjectOwnership: BucketOwnerEnforced
Expand Down
Loading