To start using the Tanzu Service Mesh CLI, you must log in to the SaaS endpoint on which you want to perform actions.
Prerequisites
The Tanzu Service Mesh CLI interacts with Tanzu Service Mesh SaaS. Make sure that you know the URL of the Tanzu Service Mesh SaaS server.
In Tanzu Platform cloud services, generate an API token to authenticate with the Tanzu Service Mesh SaaS server. For instructions on generating an API token, see step 1 in Authentication with the Tanzu Service Mesh REST API.
Procedure
- ♦On the machine where the Tanzu Service Mesh is installed, open a terminal window and run the following CLI command.
tanzu sm login -s {SaaS server host} -t {API token}
sm
is the alias for the Tanzu Service Mesh plugin in the Tanzu CLI. You can replacesm
withservice-mesh
.{SaaS server host}
is the host name in the URL of the Tanzu Service Mesh SaaS server, and{API token}
is the generated API token.For example, if the URL of the Tanzu Service Mesh SaaS server is https://my-tsm-prod.servicemesh.biz, provide the host name my-tsm-prod.servicemesh.biz in the command.
Results
You can now run other CLI commands. To get a list of the available commands, run tanzu sm -h
.