Explorar el Código

Point to the ARN instead.

Sacha Ligthert hace 3 años
padre
commit
3c1f4c6325
Se han modificado 1 ficheros con 3 adiciones y 3 borrados
  1. 3 3
      terraform.tf

+ 3 - 3
terraform.tf

@@ -72,8 +72,8 @@ data "aws_iam_policy_document" "bucket_policy_document" {
     }
     actions = ["s3:GetObject"]
     resources = [
-      aws_s3_bucket.bucket.id,
-      "${aws_s3_bucket.bucket.id}/*",
+      aws_s3_bucket.bucket.arn,
+      "${aws_s3_bucket.bucket.arn}/*",
     ]
   }
 }
@@ -164,4 +164,4 @@ resource "aws_cloudfront_distribution" "s3_distribution" {
 
 #
 # CloudFront>
-#
+#