File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 1
1
2
2
locals {
3
- ssm_patch_log_bucket_enabled = local. ssm_enabled && var. ssm_patch_manager_s3_log_bucket != " " && var. ssm_patch_manager_s3_log_bucket != null ? 1 : 0
3
+ ssm_patch_log_bucket_enabled = local. ssm_enabled && var. ssm_patch_manager_s3_log_bucket != " " && var. ssm_patch_manager_s3_log_bucket != null
4
4
ssm_policy = var. ssm_patch_manager_iam_policy == null || var. ssm_patch_manager_iam_policy == " " ? " arn:aws:iam::aws:policy/AmazonSSMManagedInstanceCore" : var. ssm_patch_manager_iam_policy
5
5
ssm_enabled = local. enabled && var. ssm_patch_manager_enabled ? true : false
6
6
}
@@ -14,7 +14,7 @@ module "label_ssm_patch_s3_log_policy" {
14
14
}
15
15
16
16
data "aws_iam_policy_document" "ssm_patch_s3_log_policy" {
17
- count = local. ssm_patch_log_bucket_enabled
17
+ count = local. ssm_patch_log_bucket_enabled ? 1 : 0
18
18
statement {
19
19
sid = " AllowAccessToPathLogBucket"
20
20
actions = [
@@ -31,7 +31,7 @@ data "aws_iam_policy_document" "ssm_patch_s3_log_policy" {
31
31
}
32
32
33
33
resource "aws_iam_policy" "ssm_patch_s3_log_policy" {
34
- count = local. ssm_patch_log_bucket_enabled
34
+ count = local. ssm_patch_log_bucket_enabled ? 1 : 0
35
35
name = module. label_ssm_patch_s3_log_policy . id
36
36
path = " /"
37
37
description = " Policy to allow the local SSM agent on the instance to write the log output to the defined bucket"
You can’t perform that action at this time.
0 commit comments