CLI Reference
Run, validate, reload, and probe Ferrum Edge v0.9.21. A subcommand is required.
Subcommands
| Command | Purpose |
|---|---|
run | Start the gateway |
validate | Validate config and startup security without serving traffic |
reload | Send SIGHUP to a running gateway (Unix only) |
health | Probe the admin API: readiness by default, liveness with --live |
version | Print version and build target |
ambient-udp-preflight | One-shot privileged Ambient UDP node preflight, run by the Helm chart as an init container |
Invoking ferrum-edge with no arguments prints usage and exits nonzero. Environment-based Docker, systemd, and shell startup must invoke ferrum-edge run.
run
| Flag | Meaning |
|---|---|
--settings PATH / -s | Operational settings (ferrum.conf) |
--spec PATH / -c | Gateway resources YAML/JSON; a localized mesh document for file-protocol mesh validation |
--mode MODE / -m | database, file, cp, dp, mesh, injector, node_agent, migrate |
--verbose / -v | Repeat for info, debug, or trace |
--fips-mode MODE | off (default) or enforce; enforcement requires a FIPS build. Set it here or in FERRUM_FIPS_MODE: a value only in ferrum.conf arrives too late and is refused |
ferrum-edge run
ferrum-edge run --settings /etc/ferrum/ferrum.conf --spec /etc/ferrum/resources.yaml
ferrum-edge run --spec resources.yaml --mode file -vv
FERRUM_MODE=database ferrum-edge run
--spec sets only the resources path (FERRUM_FILE_CONFIG_PATH). File mode is inferred from it only when no --mode flag, FERRUM_MODE environment variable (including external secret sources), or ferrum.conf value selects a mode.
validate
| Flag | Meaning |
|---|---|
--settings PATH / -s | Operational settings (ferrum.conf) |
--spec PATH / -c | Gateway resources YAML/JSON; a localized mesh document for file-protocol mesh validation |
--mode MODE / -m | database, file, cp, dp, mesh, injector, node_agent, migrate |
--verbose / -v | Repeat for info, debug, or trace |
--fips-mode MODE | off (default) or enforce; enforcement requires a FIPS build. Set it here or in FERRUM_FIPS_MODE: a value only in ferrum.conf arrives too late and is refused |
--allow-empty-namespace | Accept a document whose namespaced resources are all filtered out by FERRUM_NAMESPACE (exit 0 with a warning instead of exit 1) |
Validation checks settings, external secrets, schema version, resource and plugin fields, route uniqueness, references, namespace filtering, and startup security. File-protocol mesh documents are supported with -m mesh. Exit status is 0 on success and 1 on failure.
ferrum-edge validate --mode file --spec resources.yaml
ferrum-edge validate --settings ferrum.conf --spec resources.yaml
FERRUM_MESH_CONFIG_PROTOCOL=file ferrum-edge validate --mode mesh --spec mesh.yaml
Full gateway resource files require version: "1". Validation uses the same admission rules as run without binding sockets, connecting to a database or control plane, or applying configuration. Mesh validation also checks workload identity, so supply the same SVID or CA settings you use for run.
reload
ferrum-edge reload
ferrum-edge reload --pid 42195
Without --pid / -p, the CLI finds the running ferrum-edge process with pgrep, excluding itself; with several instances it lists their PIDs and asks you to choose. --pid 0 and the CLI's own PID are rejected.
SIGHUP hot-reloads file mode, and mesh mode when its config comes from a local file or xDS. A valid file is swapped in atomically without dropping connections; an invalid one keeps the last good configuration. Other modes log the signal and ignore it: use database polling, control-plane push, or a rolling restart.
health
ferrum-edge health # readiness: GET /health
ferrum-edge health --live # liveness: GET /live
ferrum-edge health --settings /etc/ferrum/ferrum.conf
ferrum-edge health --host 127.0.0.1 --port 9000
ferrum-edge health --tls
ferrum-edge health --tls --tls-no-verify # self-signed admin certificate, lab use only
| Flag | Meaning |
|---|---|
--settings PATH / -s | ferrum.conf used to infer the admin host and ports; environment variables take precedence |
--port PORT / -p | Admin port; defaults to FERRUM_ADMIN_HTTP_PORT (9000), or FERRUM_ADMIN_HTTPS_PORT (9443) with TLS |
--host HOST | Admin host; defaults to the effective admin bind address (0.0.0.0 probes 127.0.0.1, :: probes ::1) |
--tls | Connect over HTTPS; selected automatically when FERRUM_ADMIN_HTTP_PORT=0 and no --port is given |
--tls-no-verify | Skip certificate verification for self-signed or private-CA admin certificates |
--live | Probe liveness (GET /live) instead of readiness (GET /health) |
Exit status is 0 for HTTP 200 and 1 for anything else, including connection refused and timeouts. /health returns 503 until the gateway is ready, so point readiness probes at it; /live returns 200 whenever the process and admin listener are up, so liveness probes never restart-loop a pod that is alive but not yet ready.
livenessProbe:
exec:
command: ["/app/ferrum-edge", "health", "--live"]
readinessProbe:
exec:
command: ["/app/ferrum-edge", "health"]
The binary probe works with loopback-bound admin listeners and distroless images.
version
ferrum-edge version
# ferrum-edge 0.9.21 (aarch64-apple-darwin)
ferrum-edge version --json
# {"version":"0.9.21","target":"aarch64-apple-darwin"}
ambient-udp-preflight
The Helm chart runs this privileged command as an init container in the Ambient DaemonSet pod, so it completes before the steady-state proxy starts. It retires predecessor UDP placements on the node and publishes the cleanup proof the proxy requires, or exits nonzero without publishing anything. It does not start gateway listeners.
| Flag | Meaning |
|---|---|
--settings PATH / -s | Operational settings (ferrum.conf) |
--timeout-seconds N | Time limit before failing closed; default 300, clamped to 1–3600 |
--host-proc-root PATH | Procfs root for target PID reads; the chart mounts the host /proc read-only on this container and passes /host/proc |
--verbose / -v | Repeat for info, debug, or trace |
See the preflight reference for host mounts and capabilities.
Configuration Precedence
- CLI flags (
--settings,--spec,--mode,--fips-mode,--verbose) - Environment variables (
FERRUM_CONF_PATH,FERRUM_FILE_CONFIG_PATH,FERRUM_MODE,FERRUM_FIPS_MODE,FERRUM_LOG_LEVEL), including_FILEand cloud secret sources - Selected
ferrum.conf - Smart path discovery
- Built-in defaults
Settings discovery checks ./ferrum.conf, ./config/ferrum.conf, and /etc/ferrum/ferrum.conf. Resource discovery checks ./resources.yaml, ./resources.json, their ./config/ equivalents, then /etc/ferrum/config.yaml and /etc/ferrum/config.json.