Skip to content

CLI Command Reference

Complete reference for all KAOS CLI commands.

kaos install

Install the KAOS operator to your Kubernetes cluster using Helm.

bash
kaos install [OPTIONS]

Options

OptionShortDefaultDescription
--namespace-nkaos-systemKubernetes namespace to install into
--release-namekaosHelm release name
--versionlatestSpecific chart version to install
--setSet Helm values (can be repeated)
--waitfalseWait for pods to be ready

Examples

Basic installation:

bash
kaos install

Install to custom namespace:

bash
kaos install -n my-agents

Install with custom values:

bash
kaos install --set gateway.enabled=true --set controllerManager.replicas=2

Install specific version and wait:

bash
kaos install --version 0.1.0 --wait

kaos uninstall

Remove the KAOS operator from your Kubernetes cluster.

bash
kaos uninstall [OPTIONS]

Options

OptionShortDefaultDescription
--namespace-nkaos-systemNamespace to uninstall from
--release-namekaosHelm release name

Examples

bash
kaos uninstall
kaos uninstall -n my-agents

kaos ui

Start a CORS-enabled proxy to the Kubernetes API and open the KAOS web UI.

bash
kaos ui [OPTIONS]

Options

OptionDefaultDescription
--k8s-urlautoKubernetes API server URL. Uses kubeconfig if not specified
--expose-port8080Port for the local CORS proxy
--no-browserfalseDon't automatically open the browser

How it Works

The kaos ui command:

  1. Reads your kubeconfig to find the Kubernetes API server
  2. Starts a local CORS-enabled reverse proxy on the specified port
  3. Opens the KAOS UI in your default browser
  4. The UI connects to your cluster through the local proxy

Examples

Start with defaults:

bash
kaos ui

Use custom port:

bash
kaos ui --expose-port 9090

Connect to specific cluster:

bash
kaos ui --k8s-url https://my-cluster.example.com:6443

Start without opening browser:

bash
kaos ui --no-browser

kaos version

Display the KAOS CLI version.

bash
kaos version

Output

kaos-cli 0.1.0

Environment Variables

The CLI respects standard Kubernetes environment variables:

VariableDescription
KUBECONFIGPath to kubeconfig file
KUBERNETES_SERVICE_HOSTIn-cluster API host
KUBERNETES_SERVICE_PORTIn-cluster API port

Exit Codes

CodeMeaning
0Success
1Error (see error message)

Troubleshooting

Helm not found

Error: helm is not installed. Please install helm first.

Install Helm from https://helm.sh/docs/intro/install/

Cannot connect to cluster

Ensure kubectl is configured correctly:

bash
kubectl cluster-info

Port already in use

Use a different port for the UI proxy:

bash
kaos ui --expose-port 9090

Released under the Apache 2.0 License.