daemonocle
daemonocle copied to clipboard
Integration with systemd
I think it would be very nice to have an example on how to deploy a deamonocle daemon with systemd. Said differently, how to write a foo.service that works with daemonocle.
Well after some reading I think this is very straightforward:
[Unit]
SourcePath=/home/pi/daemon/daemon
Description=My Juicy Daemon
Before=multi-user.target
[Service]
Type=notify
PIDFile=/var/run/my-juicy-daemon.pid
Restart=no
ExecStart=/home/pi/daemon/daemon start
ExecStop=/home/pi/daemon/daemon stop
ExecReload=/home/pi/daemon/daemon reload