New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[cli] Loading rke config doesn't work #25416
Comments
Confirmed in Rancher 2.4.3 with Rancher CLI 2.4.3-rc1 Replication Run
Check cluster settings in API Result: User specified RKE config is not applied Workaround Change all key names from snake to camel case, e.g.:
|
Duplicate of #27982 gz#15447 |
The Workaround is not helping, some keys are not working at all.
It never changes and stays by default. |
@zaggash did you tried: |
Reproduced with CLI v2.4.13. This is definitely a CLI issue and has to do with how we parse top-level keys in the RKE config file. I don't yet know why (will inquire), but we convert all top-level keys to JSON format. For example, |
I may have to ascertain the exact reason for this behavior, but looks like, indeed, it has to do with how we parse/unmarshal the given config file. |
Also, for all keys inside |
Opened a PR for the change, but a draft currently, in light of the 2.6.3 release. Will mark as ready for review once 2.6.3 is out, targeting 2.6.4. |
QA TestingRoot causeImproper config deserialization - wrong top-level field was used, so all fields were ignored. What was fixed, or what changes have occurredNow the necessary value is used to deserialize the RKE config. Areas or cases that should be testedWhat areas could experience regressions?Not all fields can be properly handled, unfortunately. Otherwise, there would be a breaking change needed. Some fields need to be in a certain case, so users need to check those. For example, for all keys inside Steps
|
Test Environment:Rancher version: v2.6-head e55a04c Downstream cluster type: rancher cli Testing:Tested this issue with the following steps:
Result - Low Pass After creating the cluster, the YAML was inspected and it seems only backupConfig service had the YAML settings applied. The other settings do not seem to have the settings applied as mentioned in the testing steps. The following settings were not set with the values from the cluster.yml file.
Below is the full YAML file after creating cluster using rancher v2.6.4-rc1 cli with the configurations given in the previous comment.
|
@timhaneunsoo, just to make sure - for the config file, did you use the example from my comment or from the issue description? |
After review, the fix was found in rancher cli v2.6.4-rc2. Upon testing with the updated cli version, the fix is confirmed and testing is Pass.
Currently the CLI download found in the Rancher UI v2.6-head is v2.6.4-rc1 so I ran into the error while testing. The CLI download will be updated to the latest version before the release. |
What kind of request is this (question/bug/enhancement/feature request):
We try to create cluster using rancher cli. When we load a rke configuration with cloud_provider vsphere the virtual_center is not set.
Steps to reproduce (least amount of steps as possible):
Generate RKE configuration with rke binary
Create a cluster using rancher cli with --rke-config option
The text was updated successfully, but these errors were encountered: