Logger: Add systemd unit file
Closed this issue · 3 comments
For systemd, we need either Type=forking
and a PID file created by the daemon, or Type=simple
and the daemon not forking into background on its own. PID file support is a better fit to also support other init systems, while ability to not fork is friendlier to systemd. We can also support both.
For a non-forking mode, we can implement the -D
command-line option like sshd
has. Unfortunately, in popa3d
that option name has the opposite meaning.
Per discussion in #95, we should have make install
put the unit file in /etc/systemd/system
, but lkrg.spec
put it in /usr/lib/systemd/system
. I'm not sure that is exactly right, but it's the convention we arrived at back then and implemented for LKRG's unit file.
The -D
option is now added, a systemd unit file using it is also added, and make install
is updated accordingly. RPM packaging is not yet updated, but we have a separate issue for that. So I'm closing this one.