File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ data "template_file" "aws_iam_role_policy" {
1616 # This checks to see if a new bucket exists (null check)
1717 # If it is null, just give a null so coalesce skips it
1818 # If not null, return the arn of the bucket, which is what we really need
19- s3_resource = coalesce ((length (aws_s3_bucket. bucket ) > 0 ? aws_s3_bucket. bucket [0 ]. arn : " " ), var. existing_cloudtrail . s3_bucket_arn )
19+ s3_resource = coalesce ((length (aws_s3_bucket. bucket ) > 0 ? aws_s3_bucket. bucket [0 ]. arn : " " ), ( var. existing_cloudtrail != null ? var . existing_cloudtrail . s3_bucket_arn : " " ) )
2020 }
2121}
2222
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ output "s3_bucket_id" {
3939}
4040
4141output "s3_bucket_arn" {
42- value = coalesce ((length (aws_s3_bucket. bucket ) > 0 ? aws_s3_bucket. bucket [0 ]. arn : " " ), var. existing_cloudtrail . s3_bucket_arn )
42+ value = coalesce ((length (aws_s3_bucket. bucket ) > 0 ? aws_s3_bucket. bucket [0 ]. arn : " " ), ( var. existing_cloudtrail != null ? var . existing_cloudtrail . s3_bucket_arn : " " ) )
4343}
4444
4545output "iam_role_name" {
You can’t perform that action at this time.
0 commit comments