-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathtestbucket.yaml
More file actions
33 lines (31 loc) · 857 Bytes
/
testbucket.yaml
File metadata and controls
33 lines (31 loc) · 857 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
AWSTemplateFormatVersion: 2010-09-09
Description: "Creating an s3 bucket to host static content"
Parameters:
S3BucketName:
Type: String
Description: "Name of S3Bucket"
Resources:
S3Bucket:
Type: AWS::S3::Bucket
Properties:
AccessControl: PublicRead
WebsiteConfiguration:
IndexDocument: index.html
ErrorDocument: error.html
BucketPolicy:
Type: AWS::S3::BucketPolicy
Properties:
PolicyDocument:
Id: MyPolicy
Version: 2012-10-17
Statement:
- Sid: PublicReadForGetBucketObjects
Effect: Allow
Principal: '*'
Action: 's3:GetObject'
Resource: !Join
- ''
- - 'arn:aws:s3:::'
- !Ref S3Bucket
- /*
Bucket: !Ref S3Bucket