I'm trying to generate kubeconfig, from an EKS clu...
# aws
h
I'm trying to generate kubeconfig, from an EKS cluster, to be used to install helm charts basically i have, created EKS (and dependencies - IAM/VPC) following official examples: https://github.com/pulumi/examples/blob/master/aws-py-eks/__main__.py sadly the generated kubeconfig, doesn't work, and i need to manually run:
Copy code
aws eks --region us-east-2 update-kubeconfig --name $(pulumi stack output cluster-name)
any ideas ?
s
Can you show us how you are generating the Kubeconfig? And are you using the EKS component (
pulumi/eks
)?
h
sorry I used pulumi-aws package, i wasnt aware of the eks specific package, will check it
s
@helpful-gpu-85265 You don’t have to use the EKS-specific package; I was just asking if you were using it because the method for generating the Kubeconfig is different for the EKS package. Either approach is perfectly acceptable!
h
@salmon-account-74572 Can you give pointers on the method for generating kubeconfig for aws-native? Thanks
h
@helpful-continent-37250 i havent used the aws-native package, but i imagine you can do it similar to this example: https://github.com/pulumi/examples/blob/master/aws-py-eks/utils.py you can fetch the cluster endpoint, certificate authority, and eventually the token is generated via aws-authenticator or eks generate token
s
Hey! Sorry for the delay in responding; I was out on PTO for the holiday. Yes, what @helpful-gpu-85265 said. 🙂 The link that Amin posted should work for AWS Native. If you run into issues, let us know!