dashboard
dashboard copied to clipboard
Custom Cluster Registration for rke2 windows nodes formats taints, labels incorrectly for powershell
Setup
- Rancher version: v2.7.6
- Rancher UI Extensions: n/a
- Browser type & version: chrome (any)
Describe the bug
the windows node registration command isn't properly adding Labels and/or Taints are not formatted correctly. Windows is requesting that they have 1 flag per request, but we currently add a new - Label '<label=value>'
per label instead of what windows is asking for, - Label '<label1=value1,label2=value2,...>'
To Reproduce
create a custom rke2 cluster register a windows node with 1 label and 2 taints
Result windows node fails to register with generated registration command from rancher
Expected Result
resulting registration command should work with windows.
Screenshots
Additional context
C:\Users\administrator\install.ps1 : Cannot bind parameter because parameter 'Label' is specified more than once. To
provide multiple values to parameters that can accept multiple values, use the array syntax. For example, "-parameter
value1,value2,value3".
At line:1 char:379
+ ... -InternalAddress "172.31.42.161" -NodeName "test-ctw" -Label "tnl=tn ...
+ ~~~~~~
+ CategoryInfo : InvalidArgument: (:) [install.ps1], ParameterBindingException
+ FullyQualifiedErrorId : ParameterAlreadyBound,install.ps1