Description of problem: On 4.5 client, oc version executed without any kubeconfig file fails, but it works on 4.4 showing, at least, the client version $ 4.4/oc version Client Version: 4.4.0-0.nightly-2020-04-23-042651 $ 4.5/oc version error: Missing or incomplete configuration info. Please point to an existing, complete config file: 1. Via the command-line flag --kubeconfig 2. Via the KUBECONFIG environment variable 3. In your home directory as ~/.kube/config To view or setup config directly use the 'config' command. Version-Release number of selected component (if applicable): 4.5.0-0.nightly-2020-04-23-081727 How reproducible: 1. Download tools from nightly version `oc adm release extract --tools registry.svc.ci.openshift.org/ocp/release:4.5.0-0.nightly-2020-04-23-081727` 2. Extract `tar xzvf openshift-client-linux-4.5.0-0.nightly-2020-04-23-081727.tar.gz` 3. Unset any kubeconfig and delete any ~/.kube/config file Actual results: Command fails Expected results: If no kubeconfig file is detected, it should print, at least, the client info Additional info:
This is a known upstream problem, we'll need to pick these 2 PRs: - https://github.com/kubernetes/kubernetes/pull/90243 - https://github.com/kubernetes/kubernetes/pull/89913
Should be fixed in https://github.com/openshift/oc/pull/409
[yinzhou@localhost ~]$ oc version --kubeconfig=/tmp/kubeconfig -o yaml clientVersion: buildDate: "2020-05-07T22:03:52Z" compiler: gc gitCommit: f415627b3a8df305c4dd0ada0b4bc1271846a777 gitTreeState: clean gitVersion: 4.5.0-202005072157-f415627 goVersion: go1.13.4 major: "" minor: "" platform: linux/amd64 [yinzhou@localhost ~]$ cat /tmp/kubeconfig [yinzhou@localhost ~]$ oc version -o yaml clientVersion: buildDate: "2020-05-07T22:03:52Z" compiler: gc gitCommit: f415627b3a8df305c4dd0ada0b4bc1271846a777 gitTreeState: clean gitVersion: 4.5.0-202005072157-f415627 goVersion: go1.13.4 major: "" minor: "" platform: linux/amd64
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:2409