Is there an existing issue for this?
Current Behavior
Fleet CLI doens´t honour the --kubeconfig flag for apply and cleanup subcommands.
Expected Behavior
Fleet CLI should use the specified value when --kubeconfig is passed instead of falling back to the default location.
Steps To Reproduce
- Install fleet CLI.
- Follow the documented steps to clone the repository & execute
fleet apply.
- Launch fleet apply following the example. The execution fails:
$ fleet apply --debug --debug-level 10 -n fleet-local testbundle01 simple-chart/ -o
foo.yaml --kubeconfig /etc/rancher/rke2/rke2.yaml
$ echo $?
1
- Relaunch the execution
strace -f -e trace=openat,exit_group fleet apply -n fleet-local testbundle01 simple-chart/ -o foo.yaml --kubeconfig /etc/rancher/rke2/rke2.yaml 2>&1 | grep -v SIGURG
- The execution fails because it looks for "default" config path, ignoring the --kubeconfig flag
openat(AT_FDCWD, "/root/.kube/config", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
Environment
- Architecture: arm64 & amd64
- Fleet Version: fleet version v0.15.1 (190f2815a2f6bb208d7ffd3b7da1c9f942716cc0)
Logs
Anything else?
SURE-11634
Is there an existing issue for this?
Current Behavior
Fleet CLI doens´t honour the --kubeconfig flag for
applyandcleanupsubcommands.Expected Behavior
Fleet CLI should use the specified value when
--kubeconfigis passed instead of falling back to the default location.Steps To Reproduce
fleet apply.Environment
Logs
Anything else?
SURE-11634