1

I have Openshift CLI 3.11 installed on my machine, but my .kube folder is present on my H drive(network drive) which is not accessible due to some network problems as I'm away from my office and connected remotely . So whenever I try to login from CLI with 'oc login xxxx:port', I get below error

enter image description here

How can I change my .kube location to C drive .

BKK
  • 340
  • 2
  • 4
  • 15

1 Answers1

0

In my understanding, you want to specify other kubeconfig file path instead of $HOME/.kube/config. Is it right ? Then this reference would be helpful for you. Refer Loading and Merging Rules for more details.

For instance, you can specify the kubeconfig "--config" option or KUBECONFIG environment value as follows.

$ oc login --config /path/to/your/config -u USERNAME -p PASSWORD

OR

$ KUBECONFIG=/path/to/your/config oc login -u USERNAME -p PASSWORD
Dharman
  • 30,962
  • 25
  • 85
  • 135
Daein Park
  • 4,393
  • 2
  • 12
  • 21