Commit Graph

3 Commits

Author SHA1 Message Date
Jarvis
a2b11118e3 fix(fleet): always bake runtime-bin into pane PATH (ignore launcher PATH)
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/pr/ci Pipeline was successful
The previous `_build_runtime_bin_prefix()` skipped candidate dirs that
were already present in the LAUNCHER process's \$PATH.  This is wrong:
the tmux pane inherits the tmux SERVER environment, not the launcher's
env.  A dir on the launcher's \$PATH may be absent from the server env,
so the prefix could come back empty and the pane would fail with
'command not found'.

Remove the `case ":${PATH}:"` check that tested against the live launcher
PATH.  Keep the existence check (`[ -d "$dir" ]`) and the dedup-within-
the-constructed-prefix guard.  The pane command's `export PATH="<prefix>:${PATH}"`
harmlessly absorbs any overlap with the server PATH.

Add test 5 to test-start-agent-session.sh: sets FAKE_RUNTIME_BIN5 on the
launcher's \$PATH and asserts it still appears in the generated pane PATH
export — directly guarding this regression.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RMoEx7hfdFGjUiCHuN1RRi
2026-06-21 12:13:20 -05:00
Jarvis
32efc13d99 fix(fleet): resolve runtime PATH for durable detached agent launch
Derive a runtime-bin PATH prefix (MOSAIC_RUNTIME_BIN override, then
npm-prefix/bin, then ~/.npm-global/bin / ~/.local/bin) and bake it
into the tmux pane command as `export PATH="<prefix>:${PATH}"; exec
<cmd>` so the runtime binary (mosaic/pi/codex) is always found in a
login+non-interactive pane shell that does not source ~/.bashrc.
Using `exec` makes the runtime the pane foreground process, eliminating
the DRIFT false-positive in `mosaic fleet ps`.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RMoEx7hfdFGjUiCHuN1RRi
2026-06-21 12:05:09 -05:00
45e2c2aad8 docs: plan durable tmux fleet install (#557)
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/push/publish Pipeline was successful
2026-06-20 16:19:19 +00:00