|
@@ -19,19 +19,20 @@ PATH=/sbin:/bin
|
|
|
|
|
|
case "$1" in
|
|
|
start)
|
|
|
- python /etc/openvpn/vpn_acct.py -s graphite-dev.illyse.org /var/run/openvpn/acct vpn1
|
|
|
- ;;
|
|
|
+ /usr/bin/python2 /etc/openvpn/vpn_acct.py -s graphite-dev.illyse.org /var/run/openvpn/acct vpn1
|
|
|
+ ;;
|
|
|
restart|reload|force-reload)
|
|
|
shift
|
|
|
$0 stop ${@}
|
|
|
sleep 1
|
|
|
$0 start ${@}
|
|
|
- ;;
|
|
|
+ ;;
|
|
|
stop)
|
|
|
- kill `cat /var/run/vpn_acct.pid`
|
|
|
- ;;
|
|
|
+ kill `cat /var/run/vpn_acct.pid`
|
|
|
+ rm -f /var/run/vpn_acct.pid
|
|
|
+ ;;
|
|
|
*)
|
|
|
- echo "Usage: $0 start|stop|restart" >&2
|
|
|
- exit 3
|
|
|
- ;;
|
|
|
+ echo "Usage: $0 start|stop|restart" >&2
|
|
|
+ exit 3
|
|
|
+ ;;
|
|
|
esac
|