Admiral

Tools & SDKs

CLI

Install the Admiral CLI on macOS, Windows, Linux, Docker, or from source, sign in, and set it up for CI.

The admiral CLI does from a terminal or a CI job what the console does in a browser: applications, environments, components, credentials, and changesets.

The CLI is under active development. This page covers installation and configuration. Command reference documentation will be added as the CLI stabilizes.

How do I install the CLI?

Install via the Admiral Homebrew tap:

brew install admiral-io/tap/admiral

To upgrade:

brew upgrade admiral

To uninstall:

brew uninstall admiral

Supports both Intel (x86_64) and Apple Silicon (arm64). Shell completions for bash, zsh, and fish are installed automatically.

How do I check the install?

admiral version

How do I configure the CLI?

The CLI reads configuration from a local config directory and supports overrides via flags and environment variables.

Signing in

admiral auth login

The CLI opens a browser to sign in and keeps a session that refreshes itself. Over SSH, add --no-browser to print the sign-in URL instead. Without a browser, admiral auth login --with-token stores an API key instead, prompted so it never reaches your shell history. admiral auth status shows who the CLI is signed in as.

To keep the key in 1Password instead, pass a reference. The CLI fetches the key with op on each run, so it is never written to disk:

echo "op://Engineering/admiral/api-key" | admiral auth login --with-token

For CI, pass an API key through the environment. It takes precedence over anything auth login stored:

export ADMIRAL_API_KEY=<key>

CLI Authentication covers sessions, scopes, precedence and where credentials live.

Configuration keys

KeyDescriptionDefault
outputDefault output formattable

Managing configuration

# Set a value
admiral config set output json

# Get a value
admiral config get output

# List all settings
admiral config list

# Remove a setting
admiral config unset output

Which flags work on every command?

These flags are available on every command and override config file values:

FlagShortDescription
--output-oOutput format: table, json, yaml, wide
--verbose-vEnable debug logging
--config-dirOverride config directory path

How do I set up shell completion?

If you installed via Homebrew, Scoop, or a Linux package, shell completions are set up automatically. To generate them manually:

# Bash
admiral completion bash > /usr/share/bash-completion/completions/admiral

# Zsh
admiral completion zsh > "${fpath[1]}/_admiral"

# Fish
admiral completion fish > ~/.config/fish/completions/admiral.fish

On this page