Skip to main content

Module runpm_config

Module runpm_config 

Source
Expand description

TOML config file parsing for the runpm PM2-style supervisor CLI.

Phase 5 of #222 (issue #428). A single runpm.toml may carry any number of [[app]] tables — runpm start --config <path> iterates them and registers each one with the daemon.

Example:

[[app]]
name = "web"
cmd  = ["node", "server.js"]
cwd  = "/srv/web"
env  = { NODE_ENV = "production" }
autorestart      = true
max_restarts     = 10
restart_delay_ms = 1000
min_uptime_ms    = 2000

Relative cwd values are resolved against the config file’s parent directory; absolute paths pass through unchanged. Empty cmd arrays and duplicate name entries are rejected with a clear error message so a typo in one entry doesn’t strand the rest of the batch.

Structs§

AppConfig
One [[app]] table inside a runpm.toml config file.
RunpmConfig
Top-level shape of a runpm.toml config file.

Enums§

RunpmConfigError
Errors raised by the runpm TOML config loader.