Skip to content

Commit 5f95549

Browse files
committed
Eliminates depends_on in policy association using ref to access entry
1 parent aadfa5d commit 5f95549

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

main.tf

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -324,11 +324,7 @@ resource "aws_eks_access_policy_association" "this" {
324324
cluster_name = aws_eks_cluster.this[0].id
325325

326326
policy_arn = each.value.association_policy_arn
327-
principal_arn = each.value.principal_arn
328-
329-
depends_on = [
330-
aws_eks_access_entry.this,
331-
]
327+
principal_arn = aws_eks_access_entry.this[each.value.entry_key].principal_arn
332328
}
333329

334330
################################################################################

0 commit comments

Comments
 (0)