From 80eaa16354f31eba6e684018d9ca85e08ff2f817 Mon Sep 17 00:00:00 2001 From: John Klug Date: Fri, 6 Dec 2019 18:43:40 -0600 Subject: Set paths consistantly --- etc/init.d/commission | 4 ++-- etc/init.d/commission-php-fpm | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) (limited to 'etc') diff --git a/etc/init.d/commission b/etc/init.d/commission index 5241176..c65fbaf 100755 --- a/etc/init.d/commission +++ b/etc/init.d/commission @@ -4,7 +4,7 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/lighttpd DAEMONNAME="lighttpd" NAME=commission -DESC="Lighttpd Web Server" +DESC="MT lighttpd Commissioning Server" OPTS="-f /etc/lighttpd-commission.conf" PIDFILE=/var/run/lighttpd-commission.pid CONF_DIR=/var/config @@ -17,6 +17,7 @@ if (($PASSWORDS == 0)) ; then # No password, so indicate commissioning mode # php-fpm-commision will be turned on as well rm -f "/run/mt-commission" + echo 'ENABLED="yes"' >"/run/mt-commission" else ENABLED="no" echo 'ENABLED="no"' >"/run/mt-commission" @@ -53,7 +54,6 @@ case "$1" in ;; reload) echo -n "Reloading $DESC: " - set -x pkill -HUP -F ${PIDFILE} "$DAEMONNAME" echo "$NAME." ;; diff --git a/etc/init.d/commission-php-fpm b/etc/init.d/commission-php-fpm index 2f18fbc..e5e1077 100755 --- a/etc/init.d/commission-php-fpm +++ b/etc/init.d/commission-php-fpm @@ -10,6 +10,7 @@ # Description: starts the PHP FastCGI Process Manager daemon ### END INIT INFO +DESC="MT php commissioning server " NAME="php-fpm-commission" prefix=/usr exec_prefix=/usr @@ -22,8 +23,6 @@ php_fpm_PID="/var/run/${NAME}.pid" php_opts="-R --fpm-config $php_fpm_CONF --pid $php_fpm_PID" ENABLED=yes -[ -f "/run/mt-commission" ] && . "/run/mt-commission" - wait_for_pid () { try=0 @@ -55,7 +54,7 @@ wait_for_pid () { case "$1" in start) - [[ -f /etc/default/commission ]] && . /etc/default/commission + [ -f "/run/mt-commission" ] && . "/run/mt-commission" if [[ $ENABLED != "yes" ]]; then echo "$NAME: disabled in /run/mt-commission" exit -- cgit v1.2.3