Last active
May 3, 2020 10:20
-
-
Save worldofprasanna/cd0d01be467301d6aee9b05d065e2a25 to your computer and use it in GitHub Desktop.
Create S3 bucket to hold static assets
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "aws_s3_bucket" "main" { | |
... | |
policy = data.aws_iam_policy_document.bucket_policy.json | |
website { | |
index_document = var.index_document | |
} | |
... | |
data "aws_iam_policy_document" "bucket_policy" { | |
... | |
actions = [ | |
"s3:GetObject", | |
... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment