When my most-recent employer went belly-up, I unfortunately lost legal
access to a bunch of tools to help with process configuration and
startup I had been creating as the need arose since 2011. Because of
this, I've now started an open source (MIT license) reimplementation of
them.
Conceptually, this is the opposite of a so-called init system and
especially, the opposite of systemd. It's meant to be a set of small
tools implemented in C¹ doing exactly one thing and aiming to do
that well which can be combined with each other as needed and
principally integrated into everything (including systemd). So far,
tools exist for starting a background process, closing inherited file
descriptors, sanitizing the environment, changing the cwd, for running a
command with different user and group ids and running a command under
supervision which will be restarted automaticallty if if terminates
unexpectedly and which can be managed _without pid files_ (systemd
obviouysly still uses).
It's assumed that programs which are to be managed will cooperate with
this and that standard UNIX facilities like sessions and process groups
will thus be sufficient. Linux-specific features, eg, accept4, are used
whenever this make sense.
There's presently no documentation for this except detailed usage
messages and a brief specification of the management protocol for
supervised processes.
The GitHub URL for this is
https://github.com/rweikusat/process-tools
¹ I was originally planning to do this in Rust because this seemed like
a nice opportunity to use it for something. However, before I got around
to start this, I learnt that the Linux DRM maintainers plan to mandate
use of Rust in future. If this language is so great that its use must be
administratively mandated because otherwise, people won't use it, I
won't, either, unless I have to maintain code already written in it.