Skip to content

ksail project list-environments

List the cluster environments declared in the workspace.
An environment is a ksail.<name>.yaml root config in the workspace root (the same
convention cluster add-environment's --from resolves against); the base ksail.yaml
is not an environment. Each declared environment is reported with its distribution
and provider, read from its config. A config that fails to load is skipped so a
single malformed file never hides the environments that do load.
Output Format:
NAME DISTRIBUTION PROVIDER CONFIG
prod Talos Hetzner ksail.prod.yaml
staging K3s Docker ksail.staging.yaml
Use --output json for machine-readable output. The JSON is an array of objects:
[
{"name": "prod", "distribution": "Talos", "provider": "Hetzner", "config": "ksail.prod.yaml"}
]
Examples:
# List the declared environments
ksail project list-environments
# Machine-readable JSON
ksail project list-environments --output json
Usage:
ksail project list-environments [flags]
Flags:
--output string Output format: text or json. Use json for machine-readable output (array of {name, distribution, provider, config}). (default "text")
Global Flags:
--benchmark Show per-activity benchmark output
--config string Path to config file (default: ksail.yaml found via directory traversal)
--experimental Enable experimental (unstable) commands and features