mirror of
https://github.com/terraform-aws-modules/terraform-aws-eks.git
synced 2025-09-09 19:32:58 +08:00
feat: Add EKS Fargate support (#1067)
Co-authored-by: Simon Gurcke <simon@gurcke.de> Co-authored-by: Daniel Piddock <33028589+dpiddockcmp@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
571da60aea
commit
0d77e30075
+4
-2
@@ -43,18 +43,20 @@ locals {
|
||||
local.auth_launch_template_worker_roles,
|
||||
local.auth_worker_roles,
|
||||
module.node_groups.aws_auth_roles,
|
||||
module.fargate.aws_auth_roles,
|
||||
) :
|
||||
{
|
||||
# Work around https://github.com/kubernetes-sigs/aws-iam-authenticator/issues/153
|
||||
# Strip the leading slash off so that Terraform doesn't think it's a regex
|
||||
rolearn = replace(role["worker_role_arn"], replace(var.iam_path, "/^//", ""), "")
|
||||
username = "system:node:{{EC2PrivateDNSName}}"
|
||||
username = role["platform"] == "fargate" ? "system:node:{{SessionName}}" : "system:node:{{EC2PrivateDNSName}}"
|
||||
groups = tolist(concat(
|
||||
[
|
||||
"system:bootstrappers",
|
||||
"system:nodes",
|
||||
],
|
||||
role["platform"] == "windows" ? ["eks:kube-proxy-windows"] : []
|
||||
role["platform"] == "windows" ? ["eks:kube-proxy-windows"] : [],
|
||||
role["platform"] == "fargate" ? ["system:node-proxier"] : [],
|
||||
))
|
||||
}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user