kubectl
terraform
helm
1. Make sure to update terraform/local.tf
values as per your environment, Below are few important items to be updated.
Update the user mapping in helm/aws-auth/values.yaml
configmap:
enabled: true
name: aws-auth
data:
mapAccounts: |
- "<aws-account-no>"
mapRoles: |
- "groups":
- "system:bootstrappers"
- "system:nodes"
"rolearn": "arn:aws:iam::<aws-account-no>:role/<aws-iam-role>"
"username": "system:node:{{EC2PrivateDNSName}}"
mapUsers: |
- "groups":
- "system:masters"
"userarn": "arn:aws:iam::<aws-account-no>:user/<iam-user1>"
"username": "<iam-user1>"
- "groups":
- "system:masters"
"userarn": "arn:aws:iam::<aws-account-no>:user/<iam-user-2>"
"username": "<iam-user-2>"
aws eks update-kubeconfig --name <eks-cluster-name> --kubeconfig ~/.kube/config --region <aws-region>
kubectl get namespaces
cd helm/
helm install -f values.yaml aws-auth ./aws-auth
kubectl get nodes