diff --git a/debian/idzebra-2.0-utils.zebrasrv.default b/debian/idzebra-2.0-utils.zebrasrv.default index ffe5e65e..4b75fdec 100644 --- a/debian/idzebra-2.0-utils.zebrasrv.default +++ b/debian/idzebra-2.0-utils.zebrasrv.default @@ -5,7 +5,7 @@ CONFIG="/etc/idzebra/zebra.cfg" # Full path to zebra server. Referred to in zebrasrv.service -DAEMON=/usr/bin/zebrasrv-2.0 +DAEMON="/usr/bin/zebrasrv-2.0" # Options that are passed to the Daemon and used in zebrasrv.service OPTIONS="-l /var/log/zebrasrv.log -u nobody -c ${CONFIG} tcp:@6:2100" diff --git a/rpm/zebrasrv.service b/rpm/zebrasrv.service index bba458e8..2de813e0 100644 --- a/rpm/zebrasrv.service +++ b/rpm/zebrasrv.service @@ -2,7 +2,7 @@ [Unit] Description=Index Data Zebra server -Documentation=man:idzebra(1) +Documentation=man:zebrasrv(8) After=network.target [Service] @@ -10,7 +10,7 @@ Type=forking EnvironmentFile=/etc/sysconfig/zebrasrv ExecStart=/bin/sh -c "exec ${DAEMON} ${OPTIONS} -p /run/zebrasrv.pid -D" PIDFile=/run/zebrasrv.pid -ReStart=on-abnormal +Restart=on-abnormal [Install] WantedBy=multi-user.target diff --git a/rpm/zebrasrv.sysconfig b/rpm/zebrasrv.sysconfig index 48965395..4b75fdec 100644 --- a/rpm/zebrasrv.sysconfig +++ b/rpm/zebrasrv.sysconfig @@ -1,5 +1,11 @@ -# zebrasrv sysconfig file -CONFIG=/etc/idzebra/zebra.cfg -# this is used in zebrasrv systemd service file (not only the final OPTIONS value) -DAEMON=/usr/bin/zebrasrv-2.0 -OPTIONS="-c $CONFIG -l /var/log/zebrasrv.log -u nobody tcp:@6:2100" +# Defaults for zebrasrv systemd service +# This is a POSIX shell fragment + +# zebra.cfg (will be supplied with option -c) +CONFIG="/etc/idzebra/zebra.cfg" + +# Full path to zebra server. Referred to in zebrasrv.service +DAEMON="/usr/bin/zebrasrv-2.0" + +# Options that are passed to the Daemon and used in zebrasrv.service +OPTIONS="-l /var/log/zebrasrv.log -u nobody -c ${CONFIG} tcp:@6:2100"