Description of problem: When virtctl fails due to authentication problems, the error messages presented to the user are misleading. Version-Release number of selected component (if applicable): $ rpm -q kubevirt-virtctl kubevirt-virtctl-0.26.1-15.el8.x86_64 $ virtctl version Client Version: version.Info{GitVersion:"v0.26.1", GitCommit:"e40ff7965e2aadbf21131626dfa3be85524e3a2c", GitTreeState:"clean", BuildDate:"2020-02-19T16:16:36Z", GoVersion:"go1.12.8", Compiler:"gc", Platform:"linux/amd64"} the server could not find the requested resource How reproducible: Run virtctl commands without credentials configured. Steps to Reproduce: 1. Run a command that requires credentials, for example: virtctl image-upload dv larsdv4 --image-path cirros-0.5.1-x86_64-disk.img --size 1G --storage-class hostpath-provisioner --insecure 2. The command fails with: the server could not find the requested resource (post datavolumes.cdi.kubevirt.io) Actual results: the server could not find the requested resource (post datavolumes.cdi.kubevirt.io) Expected results: An error message along the lines of "This command requires authentication".
I was unable to reproduce the issue. I've reduced the auth token timeout to 30 secs. Running virtctl after 20 secs returned "Unauthorized" string. Same for the command mentioned in the reproduction steps. Lars, can you please elaborate about the way you made the setup unauthenticated?
Yeah, I think something else was going on. Sorry for the noise.