Open mqqc opened 1 year ago
I'm a bit hesitant as neither Gentoo nor Alpine have fully committed to supervise-daemon
yet [1][2]. There aren't too many users of this layer whereas there's a lot of Gentoo and Alpine users who are providing a lot of "testing" every day. Is there a possibility to support both but default to start-stop-daemon
? Ideally we'd be able to enable supervision on a per-recipe basis.
The layer is already mostly using the declarative style for init scripts; would it be as simple as making sure that we set command
appropriately in each init script and define command_args
/command_args_foreground
where appropriate? I haven't looked closely, but your work in #26 makes me think this might be possible.
Yes, to clarify, I mean on a per-recipe basis instead of as a global default; that the initscripts in this repo by and large (where possible and appropriate) use supervision as a guideline, but not as a globally enforced default in rc.conf
or something like that.
The layer is already mostly using the declarative style for init scripts; would it be as simple as making sure that we set command appropriately in each init script and define command_args/command_args_foreground where appropriate? I haven't looked closely, but your work in https://github.com/jsbronder/meta-openrc/pull/26 makes me think this might be possible.
That is entirely correct, yep.
Sounds like a great direction in that case.
A lot of current initscripts either run without supervision entirely or run under
start-stop-daemon
, using pidfiles which are inherently subject to race conditions and don't provide proper supervision.While
supervise-daemon
also has its flaws, in the context of OpenRC it may be the easiest method to provide proper supervision for services, making sure we get notified when services die and they can be automatically restarted, in a configurable way.Would you be open to updating (or having me update, of course) the initscripts in
meta-openrc
to usesupervise-daemon
as a guiding principle (that is, wherever appropriate and possible)?