killproc no longer available in image
authorparmentelat <thierry.parmentelat@inria.fr>
Fri, 14 Dec 2018 12:13:12 +0000 (13:13 +0100)
committerparmentelat <thierry.parmentelat@inria.fr>
Fri, 14 Dec 2018 12:13:12 +0000 (13:13 +0100)
plc.d/dns
plc.d/httpd

index afdf55f..b72b5a3 100755 (executable)
--- a/plc.d/dns
+++ b/plc.d/dns
@@ -39,7 +39,7 @@ case "$1" in
                [ -n "$PLC_NET_DNS1" ] && echo "nameserver $PLC_NET_DNS1"
                [ -n "$PLC_NET_DNS2" -a "$PLC_NET_DNS1" != "$PLC_NET_DNS2" ] && echo "nameserver $PLC_NET_DNS2"
            ) > $rfile
-           
+
            if [ $PLC_DNS_ENABLED -eq 1 ] ; then
                ourfile=$(grep "$SIGNATURE" /etc/resolv.conf| wc -l)
                if [ $ourfile -eq 0 ] ; then
@@ -66,8 +66,8 @@ case "$1" in
            dialog "$MESSAGE"
            if [ -f "/etc/plc_resolv.conf" ] ; then
                ourfile=$(grep "$SIGNATURE" /etc/plc_resolv.conf| wc -l)
-               if [ $ourfile -ne 0 ] ; then 
-                   dialog "WARNING: original /etc/resolv.conf was generated by etc/plc.d/dns"          
+               if [ $ourfile -ne 0 ] ; then
+                   dialog "WARNING: original /etc/resolv.conf was generated by etc/plc.d/dns"
                fi
                mv -f /etc/plc_resolv.conf /etc/resolv.conf
            fi
@@ -88,7 +88,7 @@ case "$1" in
        if [ $PLC_DNS_ENABLED -eq 1 ] ; then
            MESSAGE="Stopping DNS server"
            dialog "$MESSAGE"
-           killproc plc_dnsmasq
+           pkill -f plc_dnsmasq
            check
            result ""
        fi
index 526e37c..ce5e42e 100755 (executable)
@@ -326,7 +326,7 @@ EOF
        MESSAGE=$"Stopping web server"
        dialog "$MESSAGE"
 
-       killproc plc_httpd
+       pkill -f plc_httpd
        check
 
        result "$MESSAGE"