Repository navigation
How to start a background process (http server)? #2807
Replies: 1 comment
|
The command shown is not being backgrounded. In shell syntax, &> ./dev.log means “redirect stdout and stderr to this file”; it does not contain the standalone & job-control operator. For a process that should survive after the just recipe exits, detach it from the recipe's stdin/stdout/stderr and session: If setsid is unavailable, use your platform's service supervisor instead. For a development HTTP server, systemd --user, Docker Compose, tmux, or a dedicated process manager is safer than an untracked background child because you get stop/status/log lifecycle commands. Also check whether telepresence replace is intended to remain attached: it normally owns an active intercept/replacement session, so backgrounding it means you need a separate cleanup command such as telepresence leave or telepresence quit. The key points are: &> is redirection only; trailing & is a shell background job; nohup plus redirected stdin prevents terminal closure from holding the process; setsid detaches the controlling terminal on Unix. If this fixes the apparent hang, please mark the reply as accepted. |
Uh oh!
There was an error while loading. Please reload this page.
Tried following justfile, it got stuck.
All reactions