Skip to main content

Module exit

Module exit 

Source
Expand description

Exit-code discipline — kubectl/POSIX-aligned, aligned with CellOS engineering doctrine.

All non-success exits in cellctl MUST go through CtlError::exit() so the contract between the CLI and shell scripts/CI is stable:

codemeaning
0success
1usage / config error (bad flag, missing file, …)
2API error (cellos-server returned 4xx/5xx, network)
3validation error (local schema check failed)

Errors are always written to stderr. Machine-readable output (JSON, names) always goes to stdout so it can be piped through jq, xargs, etc.

Structs§

CtlError
Structured CLI error carrying both a message and the doctrine-mandated exit code.

Enums§

ErrorKind

Type Aliases§

CtlResult