Skip to content

Latest commit

 

History

History
66 lines (48 loc) · 2.61 KB

File metadata and controls

66 lines (48 loc) · 2.61 KB

CLI reference

All commands are subcommands of gnpctl. Global options apply before the subcommand.

Global options

Option Meaning
--config PATH Config file path (overrides $GNPCONFIG).
--state PATH Override the state DB path from config.
--catalog PATH Override the catalog directory from config.

gnpctl inventory

Command Options Description
add NAME --type, -p/--param key=value (repeatable), --token-env Register a source (validated against the source type).
remove NAME Remove a source (targets untouched).
list List configured sources (name type last_poll last_error).
pull --source NAME (repeatable) Sync sources into the targets table; non-zero exit on any source error.
diff --source NAME (repeatable) Print +/~/- variance vs the DB; no writes.
show --target-errors, --undiscovered, --stale Print the targets table; filters union.

gnpctl discover

Option Description
--periodic Re-discover discovered targets older than 1h.
--force Discover all targets, ignoring discovered/last_discovery_run.
--target NAME Limit to one target.

Prints matched=… unknown=… error=…; exits non-zero if any target errored.

gnpctl modules

Per-device module enablement (see the Modules guide).

Command Options Description
enable MODULE --target NAME (required) Force the module on (2); warns if the module isn't in the device's profile.
disable MODULE --target NAME (required) Force the module off (-1).
reset MODULE --target NAME (required) Clear the operator pin, returning the module to its discovered default.
show --target NAME Render per-target module state (off / on / forced-off / forced-on).

Unknown module names and unknown targets are clean errors.

gnpctl test

Option Description
--target NAME Limit to one target (default: all discovered).

Subscribe-ONCE per path of the target's enabled modules; prints per-path ok/FAIL; not-ready for targets without a catalog_key; exits non-zero if any path failed.

gnpctl render

Option Description
--output-dir PATH Override the render output directory from config.

Renders the data plane from discovered state to files (ingress.yaml, egress.yaml, targets.yaml) — see Rendering the data plane. Requires the render config block; aborts cleanly when it is absent.