Skip to content

Commit 23b228e

Browse files
author
ofir machlof
committed
add the ability to configure policy for cross cluster OpenSearch
1 parent dde73c8 commit 23b228e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

main.tf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,10 @@ data "aws_iam_policy_document" "this" {
288288
not_actions = try(statement.value.not_actions, null)
289289
effect = try(statement.value.effect, null)
290290
resources = try(statement.value.resources,
291-
[for path in try(statement.value.resource_paths, ["*"]) : "${aws_opensearch_domain.this[0].arn}/${path}"]
291+
[
292+
for path in try(statement.value.resource_paths, ["*"]) :
293+
"${aws_opensearch_domain.this[0].arn}${path == "/*" ? "/*" : path}"
294+
]
292295
)
293296
not_resources = try(statement.value.not_resources, null)
294297

0 commit comments

Comments
 (0)