blob: 6e3294c8e06c7bfc7d157953ddae3c97663a70aa (
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
|
#!/sbin/runscript
# Init script for ipset
# Copyright (C) 2012 Kaarle Ritvanen
# Licensed under the terms of the GPL2
depend() {
before iptables ip6tables
}
start() {
if ls /etc/ipset.d/* &> /dev/null; then
ebegin "Loading firewall IP sets"
for f in /etc/ipset.d/*; do
/usr/sbin/ipset restore < $f
done
eend $?
fi
}
stop() {
ebegin "Flushing firewall IP sets"
/usr/sbin/ipset destroy
eend $?
}
|