mirror of
https://github.com/stylersnico/librenms.git
synced 2026-08-01 00:24:21 +02:00
Add systemd unit file for the python poller service.
Move poller-service init scripts into to scripts directory and update the documentation.
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
# poller-service - SNMP polling service for LibreNMS
|
||||
|
||||
description "SNMP polling service for LibreNMS"
|
||||
author "Clint Armstrong <clint@clintarmstrong.net>"
|
||||
|
||||
# When to start the service
|
||||
start on runlevel [2345]
|
||||
|
||||
# When to stop the service
|
||||
stop on runlevel [016]
|
||||
|
||||
# Automatically restart process if crashed
|
||||
respawn
|
||||
|
||||
# Restart an unlimited amount of times
|
||||
respawn limit unlimited
|
||||
|
||||
chdir /opt/librenms
|
||||
setuid librenms
|
||||
setgid librenms
|
||||
|
||||
# Start the process
|
||||
exec /opt/librenms/poller-service.py
|
||||
|
||||
# Wait 60 seconds before restart
|
||||
post-stop exec sleep 60
|
||||
Reference in New Issue
Block a user