summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2019-06-30 09:27:47 +0200
committerMichał Górny <mgorny@gentoo.org>2019-06-30 09:39:17 +0200
commit139c59e8efd24827e28abe21b2053a591ca082f4 (patch)
tree6a97992aa869316a8942d8dbdfc4b289299d5906 /net-misc/miniupnpd/files
parentnet-misc/miniupnpd: Invert boolean for calling iptables (diff)
downloadgentoo-139c59e8efd24827e28abe21b2053a591ca082f4.tar.gz
gentoo-139c59e8efd24827e28abe21b2053a591ca082f4.tar.bz2
gentoo-139c59e8efd24827e28abe21b2053a591ca082f4.zip
net-misc/miniupnpd: Support running ip6tables setup scripts
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'net-misc/miniupnpd/files')
-rw-r--r--net-misc/miniupnpd/files/miniupnpd-conf.d-r23
-rw-r--r--net-misc/miniupnpd/files/miniupnpd-init.d-r28
2 files changed, 10 insertions, 1 deletions
diff --git a/net-misc/miniupnpd/files/miniupnpd-conf.d-r2 b/net-misc/miniupnpd/files/miniupnpd-conf.d-r2
index 2ebd8c56b57e..d0f5ce40cdc6 100644
--- a/net-misc/miniupnpd/files/miniupnpd-conf.d-r2
+++ b/net-misc/miniupnpd/files/miniupnpd-conf.d-r2
@@ -8,3 +8,6 @@
# enable manipulating iptables on start/stop
iptables_scripts=1
+
+# enable manipulating ip6tables on start/stop
+ip6tables_scripts=1
diff --git a/net-misc/miniupnpd/files/miniupnpd-init.d-r2 b/net-misc/miniupnpd/files/miniupnpd-init.d-r2
index 8b9f0579f223..4671ba067c45 100644
--- a/net-misc/miniupnpd/files/miniupnpd-init.d-r2
+++ b/net-misc/miniupnpd/files/miniupnpd-init.d-r2
@@ -9,7 +9,7 @@ command_args="-f ${config_file:-/etc/miniupnpd/miniupnpd.conf} ${extra_args}"
depend() {
need net
- use iptables minissdpd
+ use iptables ip6tables minissdpd
}
start_pre() {
@@ -18,6 +18,9 @@ start_pre() {
if [ -n "${iptables_scripts}" ]; then
/etc/miniupnpd/iptables_init.sh || retval=${?}
fi
+ if [ -n "${ip6tables_scripts}" ]; then
+ /etc/miniupnpd/ip6tables_init.sh || retval=${?}
+ fi
return ${retval}
}
@@ -28,6 +31,9 @@ stop_post() {
if [ -n "${iptables_scripts}" ]; then
/etc/miniupnpd/iptables_removeall.sh
fi
+ if [ -n "${ip6tables_scripts}" ]; then
+ /etc/miniupnpd/ip6tables_removeall.sh
+ fi
return ${retval}
}