Install Cloudfleet CLI

cloudfleet is the official command-line tool to access Cloudfleet services and allows you to interact with the Cloudfleet API. You can manage your infrastructure from a user-friendly command line, with all the benefits of a scriptable interface. The CLI is automatically generated based on the OpenAPI schema of the API, and you can find descriptions of endpoint input and output schemas in the API Reference section of this documentation.

Installation

Installation using a package manager is the preferred way. A package manager allows you to install and keep up with new cloudfleet versions using only a few commands.

Cloudfleet CLI is available for MacOS as a universal binary.

You can install the CLI using Homebrew:

brew install cloudfleetai/tap/cloudfleet-cli

If you do not use brew, you can download the archive via this link and extract on your system.

Cloudfleet CLI is available at Cloudfleet’s APT repository for x64 and ARM architectures. You can install it using the following commands:

curl -fsSL https://downloads.cloudfleet.ai/apt/pubkey.gpg | sudo tee /usr/share/keyrings/cloudfleet-archive-keyring.gpg >/dev/null
echo "deb [signed-by=/usr/share/keyrings/cloudfleet-archive-keyring.gpg] https://downloads.cloudfleet.ai/apt stable main" | sudo tee /etc/apt/sources.list.d/cloudfleet.list
sudo apt-get update
sudo apt-get install cloudfleet

Cloudfleet CLI is available as RPM package:

After downloading the RPM package, you can install it using the following command:

sudo rpm -i cloudfleet.rpm

Cloudfleet CLI is available as ZIP package:

After downloading the ZIP package, you can extract it and run the cloudfleet binary.

Cloudfleet CLI is available on Winget for both AMD64 and ARM architectures and be installed by following command:

winget install Cloudfleet.CLI

Alternatively, you can download the binary directly via following links:

Download the ZIP file for your platform and extract it to a directory.

Authenticating the CLI

To set up the authentication for the CLI, you can use a human account or a API token.

User authentication

cloudfleet auth add-profile user default dc78c04e-6651-4e5d-9c04-079f6532989b

Please note that, the User authentication requires a browser to complete the authentication process. The CLI will open a browser window to authenticate the user. If you are using the CLI in a headless environment (including WSL on Windows), please use the token-based authentication as a workaround. We are working to fix this issue.

Token based authentication

You can use an API token to authenticate the CLI. Refer to the API Tokens section for more information on creating and managing API tokens.

Once you have a token ID and secret, you can add a profile to the CLI configuration using the following command:

cloudfleet auth add-profile token default ORGANIZATION_ID TOKEN_ID TOKEN_SECRET

Please replace ORGANIZATION_ID, TOKEN_ID, and TOKEN_SECRET with the actual values.

Please note that the API token authentication is designed for programmatic access. If you are using the CLI for interactive use, it is recommended to use user authentication.

Using multiple authentication profiles

You can use multiple profiles for different organizations or users. You can switch between profiles using the --profile flag.

Usage

The CLI is designed to be user-friendly and easy to use. You can access the help menu by running cloudfleet --help and get detailed information about a specific command by running cloudfleet <command> --help. You can also find detailed information about the available commands in different sections of this documentation.