Cluster CLI Reference

Cluster CLI Reference

The CLI tool has commands to create, manage, and backup Docker Clusters. By default the tool runs in interactive mode. It prompts you for the values needed.

Additional help is available for each command with the ‘–help’ option.

Usage

docker run -it --rm docker/cluster \
    command [command options]

Commands

Option Description
backup Backup a running cluster
create Create a new Docker Cluster
inspect Display detailed information about a cluster
ls List all available clusters
restore Restore a cluster from a backup
rm Remove a cluster
update Update a running cluster’s desired state
version Print Version, Commit, and Build type

Environment Variables

CLUSTER_ORGANIZATION

Specifies the Docker Hub organization to pull the cluster container.

export CLUSTER_ORGANIZATION="docker"

CLUSTER_TAG

Specifies the tag of the cluster container to pull.

export CLUSTER_TAG="latest"

DOCKER_USERNAME

Overrides docker username lookup from ~/.docker/config.json.

export DOCKER_USERNAME="ironman"

DOCKER_PASSWORD

Overrides docker password lookup from ~/.docker/config.json.

export DOCKER_PASSWORD="il0v3U3000!"