3f19c89301
It is no longer Fedora-only proxy, so rename to not confuse the user. Also documentation refer to it as "updates proxy" for a long time.
21 lines
384 B
Bash
Executable File
21 lines
384 B
Bash
Executable File
#!/bin/sh
|
|
|
|
RULE_FILTER="INPUT -i vif+ -p tcp --dport 8082 -j ACCEPT"
|
|
RULE_NAT="PR-QBS-SERVICES -i vif+ -d 10.137.255.254 -p tcp --dport 8082 -j REDIRECT"
|
|
|
|
if [ "$1" == "start" ]; then
|
|
cat <<__EOF__ | iptables-restore -n
|
|
*filter
|
|
-I $RULE_FILTER
|
|
COMMIT
|
|
*nat
|
|
-I $RULE_NAT
|
|
COMMIT
|
|
__EOF__
|
|
else
|
|
# Remove rules
|
|
iptables -D $RULE_FILTER
|
|
iptables -t nat -D $RULE_NAT
|
|
exit 0
|
|
fi
|