kpack-cli icon indicating copy to clipboard operation
kpack-cli copied to clipboard

Provide better error messages when access to the Kubernetes clusteres has expired

Open odedia opened this issue 3 years ago • 0 comments

When running kp import (and possibly other commands) against a Kubernetes cluster, and the access to that cluster is blocked/expired/invalid, the response could be misleading.

In the case of kp import, the response is failed to get default repository, use "kp config default-repository" to set...

When running a simple command such as kubectl get pods against the same expired cluster, the error would be Unauthorized.

The error in kp could be misleading and make users search for issues that are unrelated to the access problem, so it's best to have a good error message to indicate it instead.

Thanks.

odedia avatar Dec 21 '21 18:12 odedia