Skip to content

Instantly share code, notes, and snippets.

@joepindar
Created September 17, 2018 11:53
Show Gist options
  • Save joepindar/1ab8a81d1ddea98b6e679f98e86f30ef to your computer and use it in GitHub Desktop.
Save joepindar/1ab8a81d1ddea98b6e679f98e86f30ef to your computer and use it in GitHub Desktop.
AWS S3 Permissions - Global Read + Deployment User
{
"Version": "2012-10-17",
"Id": "Policy1537184900949",
"Statement": [
{
"Sid": "Public Read Access",
"Effect": "Allow",
"Principal": "*",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::<BUCKET-NAME>/*"
},
{
"Sid": "Deployment Rules Part 1",
"Effect": "Allow",
"Principal": {
"AWS": "<DEPLOYMENT-USER-ARN>"
},
"Action": [
"s3:DeleteObject",
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::<BUCKET-NAME>/*"
},
{
"Sid": "Deployment Rules Part 2",
"Effect": "Allow",
"Principal": {
"AWS": "<DEPLOYMENT-USER-ARN>"
},
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::<BUCKET-NAME>"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment