Skip to content

Commit 3e2ea83

Browse files
authored
fix: Allow "EC2" access entry type for EKS Auto Mode custom node pools (#3281)
Removed EC2 type from condition so policy attachement for access entry can be done for EC2 type for creating access entry for Node role. While Creating Access entry for Self managed node role, we were getting below error as it seems EC2 type is included in exception for policy attachment. Once I removed EC2 from exception condition, it started picking up Policy attachment and Access Entry got created. │ Error: Unsupported attribute │ │ on .terraform/modules/eks/main.tf line 289, in resource "aws_eks_access_policy_association" "this": │ 289: policy_arn = each.value.association_policy_arn │ ├──────────────── │ │ each.value is object with 3 attributes │ │ This object does not have an attribute named "association_policy_arn".
1 parent 7acf66f commit 3e2ea83

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

main.tf

+1-1
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ locals {
258258
association_policy_arn = pol_val.policy_arn
259259
association_access_scope_type = pol_val.access_scope.type
260260
association_access_scope_namespaces = lookup(pol_val.access_scope, "namespaces", [])
261-
} : k => v if !contains(["EC2", "EC2_LINUX", "EC2_WINDOWS", "FARGATE_LINUX", "HYBRID_LINUX"], lookup(entry_val, "type", "STANDARD")) },
261+
} : k => v if !contains(["EC2_LINUX", "EC2_WINDOWS", "FARGATE_LINUX", "HYBRID_LINUX"], lookup(entry_val, "type", "STANDARD")) },
262262
)
263263
]
264264
])

0 commit comments

Comments
 (0)