Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit c58a11f

Browse files
🆗 fix bucket policy to suppress change in every plan/apply
1 parent ed21ff8 commit c58a11f

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

‎examples/minimal/main.tf

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,19 +39,19 @@ resource "aws_s3_bucket" "test" {
3939

4040
policy = <<EOF
4141
{
42-
"Version":"2012年10月17日",
43-
"Id":"PolicyForCloudFrontPrivateContent",
44-
"Statement":[
42+
"Id": "PolicyForCloudFrontPrivateContent",
43+
"Statement": [
4544
{
46-
"Sid": "Grant a CloudFront Origin Identity access to support private content",
45+
"Action": "s3:GetObject",
4746
"Effect": "Allow",
4847
"Principal": {
49-
"CanonicalUser": "${aws_cloudfront_origin_access_identity.test.s3_canonical_user_id}"
48+
"AWS": "${aws_cloudfront_origin_access_identity.test.iam_arn}"
5049
},
51-
"Action": "s3:GetObject",
52-
"Resource": "arn:aws:s3:::${var.s3_bucket_name}/*"
50+
"Resource": "arn:aws:s3:::${var.s3_bucket_name}/*",
51+
"Sid": "Grant a CloudFront Origin Identity access to support private content"
5352
}
54-
]
53+
],
54+
"Version": "2012年10月17日"
5555
}
5656
EOF
5757
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /