helix stop¶
Stop the background daemon started by helix start (or any process
whose PID lives in /tmp/helix.pid). The handshake is graceful: SIGTERM
first, then a 10-second grace period, then SIGKILL if the process is
still alive.
Usage¶
Flags¶
This subcommand takes no flags and no arguments.
Behavior notes¶
- Requires
$HELIX_LICENSE. Even though stopping doesn't load a flow, the license gate runs first; this is intentional so an unlicensed binary can't be used to manage a licensed one. - Reads
/tmp/helix.pid. If the file is missing or the PID is no longer running, printsHelix is not runningand returns success (exit 0). Stale PID files are cleaned up automatically. - Sends
os.Interrupt(SIGTERM on Unix) to the child. Then polls every 500ms for up to 10 seconds (20 iterations) waiting for the process to exit gracefully — the engine drains in-flight exchanges withinhelix.shutdown.drain_timeoutduring this window. - After 10 seconds, force-kills with
process.Kill()(SIGKILL on Unix) and printsHelix force-killed. - Always removes
/tmp/helix.pidon exit, even if the process was already dead.
Exit codes¶
0— daemon stopped (or was not running)1— unable to find or signal the process (rare; typically a stale PID file)
Examples¶
Stop a running daemon:
Stop + start to pick up edits:
Source¶
cmd/helix/main.go lines 1300-1338 (cmdStop)
See also¶
helix start,helix restart,helix statushelix run— the foreground equivalent