Eksctl: name is not required when config is used

Created on 18 Mar 2019  路  4Comments  路  Source: weaveworks/eksctl

We have this right now

Usage: eksctl delete cluster [flags]

General flags:
  -n, --name string          EKS cluster name (required)
  -r, --region string        AWS region
  -w, --wait                 wait for deletion of all resources before exiting
  -f, --config-file string   load configuration from a file 

We could say something like this

  -n, --name string          EKS cluster name (required, unless --config-file/-f is given)

But perhaps simpler is better

  -n, --name string          EKS cluster name

If someone doesn't pass --name, they will get an error anyway.

aregeneral-cli good first issue help wanted

Most helpful comment

Yes, nodegroup commands take --cluster, because there --name refers to nodegroup's name. Having --cluster-name and --nodegroup-name would make it more explicit, but keeping backwards compatible flags around may become a cause for confusion. I think this is separate discussion, and I'm not so sure if it's a high priority one. I would rather make sure we have consistent support for --config-file, fix more pressing issue (like deletions), and get closer to eksctl apply and promoting the API to v1beta1.

All 4 comments

Side comment: Some commands use --name <cluster name> and some --cluster <cluster name>. I can't tell you which because I'm endlessly confused and just guess each time 馃槃. Could we take a consistent approach?

Ok, I checked and e.g. the nodegroup commands switch the cluster name to --cluster. Could we start allowing --cluster-name and --nodegroup-name so we have consistent approach across eksctl subcommands? More like the AWS CLI.

Yes, nodegroup commands take --cluster, because there --name refers to nodegroup's name. Having --cluster-name and --nodegroup-name would make it more explicit, but keeping backwards compatible flags around may become a cause for confusion. I think this is separate discussion, and I'm not so sure if it's a high priority one. I would rather make sure we have consistent support for --config-file, fix more pressing issue (like deletions), and get closer to eksctl apply and promoting the API to v1beta1.

I removed the (required) from the all cluster name help message scenarios and I made an initial PR.

Is that what you expect @errordeveloper?

Thank you!

Was this page helpful?
0 / 5 - 0 ratings