Support for setting PIDFile for "forking" daemons
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
snapd |
Triaged
|
Wishlist
|
Unassigned |
Bug Description
The man page for systemd's service unit says that if the service is set with `Type=forking`, then the service unit should also specify a PID file with the `PIDFile` specification.
Currently in snaps, you can declare an app as a forking daemon with `daemon: forking` in the snap{,craft}.yaml, but you cannot specify the PIDFile for that daemon as is recommended in the man page. See:
If set to forking, it is expected that the process configured with ExecStart= will
call fork() as part of its start-up. The parent process is expected to exit when
start-up is complete and all communication channels are set up. The child continues to
run as the main daemon process. This is the behavior of traditional UNIX daemons. If
this setting is used, it is recommended to also use the PIDFile= option, so that
systemd can identify the main process of the daemon. systemd will proceed with
starting follow-up units as soon as the parent process exits.
from http://
This is a reasonable claim: I'm marking it as a whishlist because it is a new feature.