feat: edit a s3 bucket policy to host my blog
This commit is contained in:
parent
73ce84ba2f
commit
414897d9a9
1 changed files with 11 additions and 0 deletions
|
|
@ -15,6 +15,11 @@ Resources:
|
|||
WebsiteConfiguration:
|
||||
IndexDocument: index.html
|
||||
ErrorDocument: error.html
|
||||
PublicAccessBlockConfiguration:
|
||||
BlockPublicAcls: false
|
||||
BlockPublicPolicy: false
|
||||
IgnorePublicAcls: false
|
||||
RestrictPublicBuckets: false
|
||||
|
||||
WebsiteBucketPolicy:
|
||||
Type: AWS::S3::BucketPolicy
|
||||
|
|
@ -31,6 +36,12 @@ Resources:
|
|||
- s3:PutObject
|
||||
- s3:DeleteObject
|
||||
Resource: !Sub "arn:aws:s3:::${WebsiteBucket}/*"
|
||||
- Sid: PublicReadGetObject
|
||||
Effect: Allow
|
||||
Principal: "*"
|
||||
Action:
|
||||
- s3:GetObject
|
||||
Resource: !Sub "arn:aws:s3:::${WebsiteBucket}/*"
|
||||
|
||||
CodeBuildServiceRole:
|
||||
Type: AWS::IAM::Role
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue