Skip to content

Instantly share code, notes, and snippets.

@ironbyte
Created February 27, 2021 08:57
Show Gist options
  • Save ironbyte/3abcba571da82098643422c6d4320d34 to your computer and use it in GitHub Desktop.
Save ironbyte/3abcba571da82098643422c6d4320d34 to your computer and use it in GitHub Desktop.
Note: Replace <BUCKET_NAME> with your bucket name
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "ConsoleAccess",
"Effect": "Allow",
"Action": [
"s3:GetAccountPublicAccessBlock",
"s3:GetBucketAcl",
"s3:GetBucketLocation",
"s3:GetBucketPolicyStatus",
"s3:GetBucketPublicAccessBlock",
"s3:ListAllMyBuckets"
],
"Resource": "*"
},
{
"Sid": "ListObjectsInBucket",
"Effect": "Allow",
"Action": ["s3:ListBucket"],
"Resource": [
"arn:aws:s3:::<BUCKET_NAME>"
]
},
{
"Sid": "AllObjectActions",
"Effect": "Allow",
"Action": ["s3:GetObject", "s3:putObject", "s3:deleteObject"],
"Resource": [
"arn:aws:s3:::<BUCKET_NAME>/*"
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment