Skip to content

Commit

Permalink
Update static site module (#147)
Browse files Browse the repository at this point in the history
* Update json policy

* Update policy format

* Update storage.tf to remove duplicate data reference
  • Loading branch information
danielpalmeribm authored Jul 22, 2024
1 parent bc8ab80 commit 87de0e4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
3 changes: 0 additions & 3 deletions modules/aws/ai_opt_out/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@ variable "apply_to_ous_or_accounts" {
description = "A list of AWS Organization OU IDs or AWS Account IDs that should have the Policies applied (can be empty)."
default = []
}



4 changes: 2 additions & 2 deletions modules/products/static-site/storage.tf
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ resource "aws_s3_bucket_server_side_encryption_configuration" "static_site_encry
}


data "aws_iam_policy_document" "static_site_policy_document" {
data "aws_iam_policy_document" "static_site_iam_storage_policy_document" {
statement {
sid = "PublicReadGetObject"
effect = "Allow"
Expand All @@ -62,6 +62,6 @@ data "aws_iam_policy_document" "static_site_policy_document" {

resource "aws_s3_bucket_policy" "static_site_policy" {
bucket = aws_s3_bucket.static_site.id
policy = data.aws_iam_policy_document.static_site_policy_document.json
policy = data.aws_iam_policy_document.static_site_iam_storage_policy_document.json
depends_on = [aws_s3_bucket_public_access_block.static_site_acl]
}

0 comments on commit 87de0e4

Please sign in to comment.