A new user who is created from the Bare Metal Orchestrator CLI must log in to the Bare Metal Orchestrator web UI and change the password. If the user that is created wants to continue working in the CLI, the user must log out of the web UI and log in to the CLI using the new password. To perform Bare Metal Orchestrator operations, the user must update the kubeconfig file and use that file. Complete the following steps:
Note: The following steps can also be used to update the kubeconfig file when the token expires.
- Establish a CLI session on the Bare Metal Orchestrator VM and log in. For high availability configurations, establish a CLI session using the virtual IP (VIP) of the Load Balancers for the Bare Metal Orchestrator cluster.
- Export the kubeconfig file. Run the following command:
export KUBECONFIG=<Absolute path to your kubeconfig file>
Note: We recommend that you store the kubeconfig file in ~/.kube.
- Update the kubeconfig file. Run the following command:
bmo create token --username=<username> --password=<password> --update-kubeconfig=$KUBECONFIG
where username and password are the new user credentials.