dockapps/wmppp.app/example-scripts/wmppp-stop
Doug Torrance 9d8970e27a wmppp.app: Move source files to top directory.
This way, users need only type "make" to build instead of needing to
"cd wmppp" first.
2015-05-20 10:44:41 +01:00

19 lines
433 B
Bash
Executable file

#!/bin/bash
DEVICE=ppp0
if [ -r /var/run/$DEVICE.pid ]; then
kill -INT `cat /var/run/$DEVICE.pid`
if [ ! "$?" = "0" ]; then
rm -f /var/run/$DEVICE.pid
echo >/dev/console "ERROR: Removed stale pid file"
exit 1
fi
echo >/dev/console "PPP link to $DEVICE terminated."
exit 0
fi
echo >/dev/console "ERROR: PPP link not active on $DEVICE"
exit 1