1
0
mirror of https://github.com/vimagick/dockerfiles.git synced 2024-11-24 08:52:15 +02:00
This commit is contained in:
kev 2015-06-29 10:09:28 +08:00
parent a6b5f92bae
commit 209c4be3b0

View File

@ -19,8 +19,8 @@ VOLUME /etc/privoxy
EXPOSE 8118
CMD iptables -A INPUT -s 127.0.0.1 -d 127.0.0.1 -j REJECT \
&& iptables -A INPUT -s $(ip route | grep default | awk '{print $3}') \
-d $(ip route | grep default | awk '{print $3}') \
&& iptables -A INPUT -s $(ip a s eth0 | grep -w inet | awk '{print $2}' | cut -d/ -f1) \
-d $(ip a s eth0 | grep -w inet | awk '{print $2}' | cut -d/ -f1) \
-j REJECT \
&& iptables -t filter -P OUTPUT DROP \
&& iptables -t filter -A OUTPUT -p udp --dport 53 -j ACCEPT \