updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / sova / iptables2.rc
blob842c4b909d70c0b151fb823ec77c7c7e3a090c20
1 #!/bin/bash
3 # SOVA iptables2 start/stop script.
5 # based on AUR/community/openntpd 3.9p1-7 package start/stop script
6 # by Vesa Kaihlavirta (vegai), vegai at amessage dot info
9 CONF=/etc/conf.d/iptables2
11 . /etc/rc.conf
12 . /etc/rc.d/functions
14 [ -f $CONF ] && . $CONF
16 case "$1" in
17 start)
18 stat_busy "Starting SOVA iptables2"
20 binaries_paths
21 custom_variables
22 start_iptables
24 if [ "$?" -gt 0 ]
25 then
26 stat_fail
27 else
28 stat_done
31 stop)
32 stat_busy "Stopping SOVA iptables2"
34 binaries_paths
35 custom_variables
36 stop_iptables
38 if [ "$?" -gt 0 ]
39 then
40 stat_fail
41 else
42 stat_done
45 restart)
46 $0 stop
47 sleep 2
48 $0 start
51 echo "usage: $0 {start|stop|restart}"
52 esac
54 exit 0
56 # EOF