daemonocle icon indicating copy to clipboard operation
daemonocle copied to clipboard

Integration with systemd

Open nowox opened this issue 6 years ago • 1 comments

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.

nowox avatar Feb 13 '19 10:02 nowox

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

nowox avatar Feb 13 '19 14:02 nowox