From da88f475679afbc630164850d6ce2c57984ba978 Mon Sep 17 00:00:00 2001 From: Tifaifai Maupiti Date: Wed, 31 Jan 2018 09:37:22 +0100 Subject: [PATCH] CONFIG parameter Signed-off-by: Tifaifai Maupiti --- debian/mosquitto.init | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/debian/mosquitto.init b/debian/mosquitto.init index 5613d19f..210bcce5 100755 --- a/debian/mosquitto.init +++ b/debian/mosquitto.init @@ -22,6 +22,7 @@ set -e PIDFILE=/var/run/mosquitto.pid DAEMON=/usr/sbin/mosquitto +CONFIG=/etc/mosquitto/mosquitto.conf # /etc/init.d/mosquitto: start and stop the mosquitto MQTT message broker @@ -44,7 +45,7 @@ case "$1" in exit 1 fi log_daemon_msg "Starting network daemon:" "mosquitto" - if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c /etc/mosquitto/mosquitto.conf ; then + if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c ${CONFIG} ; then log_end_msg 0 else log_end_msg 1 @@ -84,7 +85,7 @@ case "$1" in if start-stop-daemon --stop --quiet --oknodo --retry 30 --pidfile ${PIDFILE}; then rm -f ${PIDFILE} fi - if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c /etc/mosquitto/mosquitto.conf ; then + if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c ${CONFIG} ; then log_end_msg 0 else log_end_msg 1 @@ -104,7 +105,7 @@ case "$1" in 0) # old daemon stopped rm -f ${PIDFILE} - if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c /etc/mosquitto/mosquitto.conf ; then + if start-stop-daemon --start --quiet --oknodo --background --make-pidfile --pidfile ${PIDFILE} --exec ${DAEMON} -- -c ${CONFIG} ; then log_end_msg 0 else log_end_msg 1