diff --git a/docs/deployment.png b/docs/deployment.png index 0fc06d14..79d00082 100644 Binary files a/docs/deployment.png and b/docs/deployment.png differ diff --git a/docs/virtual-network.png b/docs/virtual-network.png index 2a5b9e08..c895d541 100644 Binary files a/docs/virtual-network.png and b/docs/virtual-network.png differ diff --git a/weaver/weave b/weaver/weave index 4b323d7a..837fc178 100755 --- a/weaver/weave +++ b/weaver/weave @@ -49,9 +49,17 @@ create_bridge() { } add_nat_rule() { - if ! iptables -w -t nat -C $1 >/dev/null 2>&1 + # -w is recent addition to iptables + if [ -z "$CHECKED_IPTABLES_W" ] ; then + if iptables -S -w >/dev/null 2>&1 ; then + IPTABLES_W=-w + fi + CHECKED_IPTABLES_W=1 + fi + + if ! iptables $IPTABLES_W -t nat -C $1 >/dev/null 2>&1 then - iptables -w -t nat -A $1 >/dev/null + iptables $IPTABLES_W -t nat -A $1 >/dev/null fi }