blob: f2c2c16d49abcb977df446c6a72707d8326edcbf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#! /bin/bash
declare progname=${0##*/}
declare action=$1; shift
conf=$1; shift
test -x $bb || exit 0
start ()
{
/opt/vyatta/sbin/wan_lb -f $conf -d -i /var/run/vyatta/wlb.pid
}
stop ()
{
kill -s SIGTERM $( cat /var/run/vyatta/wlb.pid )
}
case "$action" in
start) start;;
stop) stop;;
restart) stop; sleep 1; start;;
*) echo "Usage: $progname {start|stop|restart}"
exit 1
esac
|