Add IAM Users to AWS-AUTH config to access EKS Cluster

Before you start

It’s not working for me…

Setting IAM User Group

Setting IAM User

Terraform Script

data "aws_iam_group" "developer_iam_group" {
group_name = "eks-user-group"
}
locals {
users_map_obj = [
for user in data.aws_iam_group.developer_iam_group.users: {
userarn: user.arn
username: user.user_name
groups: tolist(["system:masters"])
}
]
}
module "eks" {
source = "terraform-aws-modules/eks/aws"
version = "17.24.0"
cluster_name = local.cluster_name
cluster_version = "1.20"
subnets = module.vpc.private_subnets
map_users = local.users_map_obj
// custom code here}
Now, I can play around with EKS Cluster

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store