Summary
It was noticed that when the name entry was populated in a config file and the -C option was passed to the cluster start command with a different name, the -C name was not used, but the name entry in the config file was. For example, if config.yaml consists of
name: shouldNotBeUsed and the command used is cluster start -C nameToUse -c config.yaml, the cluster would start with the name shouldNotBeUsed. This is not ideal, as command line arguments should take precedence.
Steps to Reproduce
Create a config file with the name entry populated
Create a cluster with a different name passed in first through the -C flag, and then pass in the config file through the -c flag.
Expected Results
./ocne cluster start -w 1 -C realName -c ~/test.yaml
INFO[2024-08-28T16:46:04-04:00] Creating new Kubernetes cluster named realName
Actual Results
Test.yaml contains name: test as the only entry
./ocne cluster start -w 1 -C realName -c ~/test.yaml
INFO[2024-08-28T16:46:04-04:00] Creating new Kubernetes cluster named test
Summary It was noticed that when the name entry was populated in a config file and the -C option was passed to the cluster start command with a different name, the -C name was not used, but the name entry in the config file was. For example, if config.yaml consists of
name: shouldNotBeUsed
and the command used iscluster start -C nameToUse -c config.yaml
, the cluster would start with the name shouldNotBeUsed. This is not ideal, as command line arguments should take precedence.Steps to Reproduce
Expected Results
Actual Results Test.yaml contains
name: test
as the only entryReferences Reported By - George Aeillo