how to get or change context
Closed this issue · 3 comments
Antirecord commented
Good afternoon! Please tell me how to do kubectl config context get-contexts
on k8s java client, I want to get cluster but I don't understand how.
brendandburns commented
Antirecord commented
Get contexts: https://github.com/kubernetes-client/java/blob/master/util/src/main/java/io/kubernetes/client/util/KubeConfig.java#L147
Good afternoon! The question is how do I get the context if I use inCluster, without kubeConfig:
ApiClient client = ClientBuilder.cluster().build();
henrik242 commented
@Antirecord Did you figure this out?