Expand description
The dev supervisor, the same on the machine (--native) and in the container
(--inside): it watches the files, rebuilds, restarts the app, and writes one stream of
logs. While a build runs, or fails, the last version that built keeps answering.
Modules§
- docker
balise devin Docker. The project’scompose.yamlruns the supervisor (balise dev --inside) in a container; this side checks Docker and the port, gives compose what it derives from the configuration, and relays the container’s logs.
Constants§
- GRACE_
MARGIN - How much longer than
shutdown.timeoutthe app is given to stop before it is killed.
Functions§
- catch_
signals - Catches
SIGINTandSIGTERM. In a terminal, Ctrl-C reaches the app too, which starts its own shutdown; in a container, only the supervisor getsSIGTERM, and passes it on. - stop_
requested - Whether Ctrl-C or
SIGTERMasked the supervisor to stop. - supervise
- Runs the supervisor of the project at
rootuntilstopsays so.