Skip to content

Instantly share code, notes, and snippets.

  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save takahashi-h5/c60e36a4fc4a46242561e157299145a6 to your computer and use it in GitHub Desktop.
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "AllowUserToSeeBucketListInTheConsole",
"Action": [
"s3:ListAllMyBuckets",
"s3:GetBucketLocation"
],
"Effect": "Allow",
"Resource": [ "arn:aws:s3:::*" ]
},
{
"Sid": "AllowRootAndHomeListingOfBucket",
"Action": [
"s3:ListBucket"
],
"Effect": "Allow",
"Resource": [ "arn:aws:s3:::バケット名" ],
"Condition": {
"StringEquals": {
"s3:delimiter": [ "/" ],
"s3:prefix": [
"",
"Exports/"
]
}
}
},
{
"Sid": "AllowListingOfUserFolder",
"Action": [
"s3:ListBucket"
],
"Effect": "Allow",
"Resource": [ "arn:aws:s3:::バケット名" ],
"Condition": {
"StringLike": {
"s3:prefix": [
"Exports/*"
]
}
}
},
{
"Sid": "AllowAllS3ActionsInUserFolder",
"Action": [ "s3:*" ],
"Effect": "Allow",
"Resource": [ "arn:aws:s3:::バケット名/Exports/*" ]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment