Managing Multiple Clusters¶
teectl can be used to manage multiple Traefik Enterprise clusters simultaneously. When setting up a cluster with
teectl setup a cluster name can be given using the
To run commands on a named cluster, the
--cluster option can be used on all applicable commands:
teectl get nodes --cluster=$CLUSTER_NAME
teectl comes with additional commands to help manage multiple clusters. They are grouped under the
Instead of specifying the
--cluster option on each applicable
teectl command, the
cluster use command can be used to set the cluster context to use for all subsequent commands.
teectl cluster use --name=some-cluster
Cluster context has been set to "some-cluster"
In the example above all management commands will be run on a cluster named
To see available clusters configured in
cluster get command can be used. The current cluster context will be indicated with a
teectl cluster get
teectl to manage an existing cluster, the cluster configuration must first be imported using the
cluster import command. This will make a copy of the given cluster configuration in the correct location.
teectl cluster import --file=test.yaml
Cluster Configuration Location
teectl stores its configuration files in the
$HOME/.config/traefikee/ folder. Should this need to be customized,
the environment variable
TRAEFIKEE_HOME can be set to instruct
teectl where to look for configuration files.