May 2018
Intermediate to advanced
554 pages
13h 51m
English
Next, we are going to set up two credentials for each cluster. Use the subcommand set-credentials as kubectl config set-credentials <CREDENTIAL_NAME> to add a credential into kubeconfig. There are different authentication methods supported in Kubernetes. We could use a password, client-certificate, or token. In this example, we'll use HTTP basic authentication to simplify the scenario. Kubernetes also supports client certificate and token authentications. For more information, please fire the set-credentials command with the flag -h for a detailed introduction to its functionalities:
// check the details of setting up credentials$ kubectl config set-credentials -h// in localhost cluster, copy the based file into a ...