Install and Upgrade the CD-as-a-Service CLI

Install the Armory Continuous Deployment-as-a-Service CLI natively on Mac, Linux, or Windows. Learn how to run the CLI in Docker.

CLI overview

You can install the CLI (armory) on your Mac, Linux, or Windows workstation. Additionally, you can run the CLI in Docker.

On Mac, you can also download, install, and update the CLI using the Armory Version Manager (AVM). The AVM includes additional features such as the ability to list installed CLI versions and to declare which version of the CLI to use.

brew tap armory-io/armory
brew install armory-cli

You can install the CLI with a one-line script that does the following:

  1. Fetches the correct Armory Version Manager binary (avm) for your operating system
  2. Installs the AVM binary
  3. Uses the AVM to install the CLI binary (armory)
  4. Adds the AVM and the CLI to the path in your bash or zsh profile

Execute the following script on the machine that has access to your Kubernetes cluster:

curl -sL | bash

After installation completes, you should start a new terminal session or source your profile.

  1. Download the AVM for your operating system and CPU architecture. You can manually download it from the repo or use the following command:

    curl -LO<os>-<architecture>

    For example, the following command downloads the latest version for macOS (Darwin):

    curl -LO

    You can see the full list of available releases in the repo.

  2. Give AVM execute permissions. For example (on macOS):

    chmod +x avm-darwin-amd64
  3. Confirm that /usr/local/bin is on your PATH:

    echo $PATH

    The command returns your PATH, which should now include /usr/local/bin/.

  4. Rename the AVM binary to avm and move it to /usr/local/bin, which is on your PATH. For example (on macOS):

    mv avm-darwin-amd64 /usr/local/bin/avm
  5. Run the following command to install the CLI:

    avm install

    The command installs the CLI and returns a directory that you need to add to your path, such as /Users/milton/.avm/bin.

    If you get an developer cannot be identified error when trying to run AVM, you must allow AVM to run.

    Show me how to allow AVM to run.

    On macOS, go to System Preferences > Security & Privacy > General and click Allow Anyway.

    For more information, see the macOS documentation about how to open a Mac app from an unidentified developer.

  6. Add the directory that AVM returned when you ran avm install to your path.

    Show me how to add the directory.

    You can either add the path directly to /etc/paths or add it to your shell profile. The following steps describe how to add it to your shell profile:

    1. Edit the resource file for your shell, such as .bashrc, .bash_profile, or .zshrc. For example:

      vi ~/.bashrc
    2. In the file, find the line for the PATH that your resource file exports. They follow the format export PATH=$HOME/bin:/usr/local/bin:$PATH.

    3. Insert the path provided by AVM (such as /Users/brianle/.avm/bin) before the ending $PATH. The line should look similar to this:

      export PATH=$HOME/bin:/usr/local/bin::/Users/milton/.avm/bin:$PATH
    4. Save the file.

    5. Reload your terminal, open a new session, or source your terminal profile file (for example, source .bash_profile).

  7. Run the following command to verify that the CLI is installed:


    The command returns basic information about the CLI, including available commands.

For the AVM or the CLI, you can use the -h flag for more information about specific commands.

Armory provides the CD-as-a-Service CLI as a Docker image.

docker pull armory/armory-cli

Download the latest armory-cli Windows executable from the repo Releases page. Install on the machine that has access to your Kubernetes cluster.

Upgrade the CLI

brew upgrade armory-cli
avm install

Monitor deployments

If you want to monitor your deployment in your terminal, use the --watch flag to output deployment status.

armory deploy start  -f deployment.yaml --watch

Output is similar to:

[2023-05-24T13:43:35-05:00] Waiting for deployment to complete. Status UI:
[2023-05-24T13:43:46-05:00] Deployment status changed: RUNNING
[2023-05-24T13:44:06-05:00] Deployment status changed: AWAITING_APPROVAL
[2023-05-24T13:44:36-05:00] Deployment status changed: RUNNING
[2023-05-24T13:44:56-05:00] Deployment status changed: AWAITING_APPROVAL
[2023-05-24T13:45:06-05:00] Deployment status changed: RUNNING
[2023-05-24T13:45:26-05:00] Deployment status changed: SUCCEEDED
[2023-05-24T13:45:26-05:00] Deployment 03fe43c6-ddc1-49d8-8116-b01db0ca0c5a completed with status: SUCCEEDED
[2023-05-24T13:45:26-05:00] Deployment ID: 03fe43c6-ddc1-49d8-8116-b01db0ca0c5a
[2023-05-24T13:45:26-05:00] See the deployment status UI:

If you forget to add the --watch flag, you can run the armory deploy status --deploymentID <deployment-id> command. Use the Deployment ID returned by the armory deploy start command. For example:

armory deploy start -f deployment.yaml
Deployment ID: 9bfb67e9-41c1-41e8-b01f-e7ad6ab9d90e
See the deployment status UI:

then run:

armory deploy status --deploymentId 9bfb67e9-41c1-41e8-b01f-e7ad6ab9d90e

Output is similar to:

application: sample-application, started: 2023-01-06T20:07:36Z
status: RUNNING
See the deployment status UI: environmentId=82431eae-1244-4855-81bd-9a4bc165f90b

This armory deploy status command returns a point-in-time status and exits. It does not watch the deployment.

Last modified September 20, 2023: (3fc79be)