Contexts

Last updated 5 months ago

Kubernetic uses ~/.kube/config file to find existing cluster contexts and handle authentication. This means that as soon as you have a kubectl client configured to your machine Kubernetic will be able to login to your configured clusters.

At the moment Kubernetic only reads configuration so you first need to configure your authentication using kubectl commands. Follow the guide here for more details on how to configure ~/.kube/config file.

Settings > Contexts: Switch between Kubernetes contexts

Once you manage to login to your cluster continue to the next section.

Kubernetic and CLI tools share current context

  • Kubernetic monitors the ~/kube/configfor changes so if you switch between contexts on CLI either using kubectlor with kubectx it will refresh automatically with new context.

  • If you change context in Kubernetic the change is reflected on Kube config and CLI tools.