Skip to content

Commit 57626e4

Browse files
angelchargemartinsengelhartsbryantbiggsantonbabenko
authored
fix: Cloudwatch policy for pipes (#140)
Co-authored-by: Engelharts, Martins <[email protected]> Co-authored-by: Bryant Biggs <[email protected]> Co-authored-by: Anton Babenko <[email protected]>
1 parent e154130 commit 57626e4

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

iam_pipes.tf

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,16 @@ locals {
6060
matching_services = ["batch"]
6161
},
6262
logs = {
63-
values = [v.target],
63+
values = flatten([
64+
"${v.target}:*",
65+
[
66+
for pipe in var.pipes : [
67+
for log_config in try([pipe.log_configuration], []) : [
68+
for cloudwatch_log in try([log_config.cloudwatch_logs_log_destination], []) : "${cloudwatch_log.log_group_arn}:*"
69+
]
70+
]
71+
]
72+
]),
6473
matching_services = ["logs"]
6574
},
6675
ecs = {

0 commit comments

Comments
 (0)