Consul K8s CLI Reference
Consul K8s CLI is is currently availabe as a beta release and is not recommended for production environments.
Clone the consul-k8s project.
Navigate to the
consul-k8s/cli
directory and issue the following command to build the tool:(Optional) Move the binary to you
$PATH
for ease of use, e.g.:mv consul-k8s /usr/local/bin/consul-k8s
Consul K8s CLI uses the following syntax:
The install
command installs Consul on Kubernetes.
consul-k8s install <OPTIONS>
The following options are available.
See for additional commands that you can use when installing Consul on Kubernetes.
Example Commands
The following example command installs Consul according in the myNS
namespace according to the secure
preset.
consul-k8s install -preset=secure -namespace=myNS
The following example commands install Consul on Kubernetes using custom values, files, or strings that are set via flags. The underlying Consul-on-Kubernetes Helm chart uses the flags to customize the installation. The flags are comparable to the helm install
.
uninstall
The uninstall
command removes Consul from Kubernetes.
consul-k8s uninstall <OPTIONS>
See for additional commands that you can use when uninstalling Consul from Kubernetes.
Example Command
The following example command immediately uninstalls Consul from the my-ns
namespace with the name my-consul
and removes PVCs and secrets associated with the installation without asking for verification:
consul-k8s uninstall -namespace=my-ns -name=my-consul -wipe-data=true -auto-approve=true
The version
command prints the Consul version.
This command does not take any options.
You can also print the version with the --version
flag.
The following global options are available.