Search code examples
amazon-web-servicesamazon-ekseksctl

eksctl "no clusters found"


I am currently trying out aws eks and I am havin a problem managing my cluster via eksctl. Now creating a cluster via eksctl works just fine using

eksctl create cluster --region [region] --name my-cluster

The cluster comes up correctly and it also shows in the AWS console Web GUI but if I try to get it with

eksctl get clusters

I get

No clusters found

I set up my roles as described in the documentation (EKS Cluster) role and added Access Key Id and Secret Access Key to my configuration. But could this be an issue with the permissions? If not, what else could it be


Solution

  • Have you tried to run:

    eksctl get clusters --region [region]
    

    What's your default region configured, probably you have it set up to a different one than the one where you created the cluster, e.g.:

    $ eksctl get clusters
    No clusters found
    
    $ eksctl get clusters --region eu-west-2
    NAME                REGION
    eksworkshop-eksctl  eu-west-2
    
    $ export AWS_REGION=eu-west-2
    $ eksctl get clusters
    NAME                REGION
    eksworkshop-eksctl  eu-west-2