Install the meshctl CLI

Use the Gloo command line interface (CLI) tool, meshctl, to set up Gloo Gateway, register clusters, describe your Gloo Gateway resources, and more.

Quick installation

Install the latest version of meshctl. Make sure to add meshctl to your PATH (see macOS, or Linux for specific instructions).

Install a specific version of the CLI

You can pass a variable on the command line to download a specific version of meshctl. The installation script uses the version and automatically detects your operating system to download the binary files from a public Google storage bucket, https://storage.googleapis.com/meshctl/. For example, if you install the latest version on a macOS workstation, the binary file is downloaded from https://storage.googleapis.com/meshctl/v2.5.1/meshctl-darwin-amd64.

  1. From the Changelog, find the release version that you want to install.

  2. Install the meshctl CLI, setting the Gloo Gateway version to install.

    curl -sL https://run.solo.io/meshctl/install | GLOO_MESH_VERSION=v2.5.1 sh -
    
  3. Add meshctl on your PATH system variable for global access on the command line. The steps vary depending on your operating system. The following example is for macOS. For more information, see macOS, or Linux.

    export PATH=$HOME/.gloo-mesh/bin:$PATH
    echo $PATH
    

    Example output:

    /Users/<name>/.gloo-mesh/bin:/usr/local/bin
    
  4. Verify that you can run meshctl commands and check the client version matches the version that you installed.

    meshctl version
    

    Example output:

        {
          "client": {
            "version": "2.5.1"
          },
        

On macOS, you might see the following warning: “meshctl” cannot be opened because it is from an unidentified developer. In the Finder app, navigate to the ~/.gloo-mesh/binmeshctl executable file, right-click the file, click Open, and confirm that you want to open the file. For more information, try searching the warning and following a guide.

Good job! You now have the version of meshctl that you want installed. Next, install Gloo Gateway in your clusters.

Upgrade the CLI

To upgrade, re-install the CLI. You can install the latest or a specific version. Make sure that your meshctl and Gloo Gateway versions match.

Upgrading the meshctl CLI does not upgrade the Gloo Gateway version that you run in your clusters.

Uninstall the CLI

To uninstall meshctl, you can delete the executable file from your system, such as on macOS in the following example.

rm ~/.gloo-mesh/bin/meshctl

Skew policy

Use the same version of the meshctl CLI as the Gloo Gateway version that is installed in your clusters.

Reference documentation

For more information about each meshctl command, see the CLI documentation or run the help flag for a command.

meshctl cluster --help