Skip to content

Commit 4072c22

Browse files
authored
fix: ACL value can be null even when using Terragrunt (terraform-aws-modules#75)
1 parent 9c04f76 commit 4072c22

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

main.tf

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
resource "aws_s3_bucket" "this" {
22
count = var.create_bucket ? 1 : 0
33

4-
bucket = var.bucket
5-
bucket_prefix = var.bucket_prefix
6-
acl = var.acl
4+
bucket = var.bucket
5+
bucket_prefix = var.bucket_prefix
6+
7+
# hack when `null` value can't be used (eg, from terragrunt, https://github.com/gruntwork-io/terragrunt/pull/1367)
8+
acl = var.acl != "null" ? var.acl : null
9+
710
tags = var.tags
811
force_destroy = var.force_destroy
912
acceleration_status = var.acceleration_status

0 commit comments

Comments
 (0)