ansible.fftdf.supernode/roles/00-system-set-network/tasks/templates/50-ifup-hooks.sh.j2

9 lines
338 B
Django/Jinja

#!/bin/bash
if [ "$IFACE" == "gre*" ];
then
iptables -t nat -A POSTROUTING -o $IFACE -j SNAT --to-source {{ ffrl_ipv4 }}
iptables -t mangle -A POSTROUTING -p tcp --tcp-flags SYN,RST SYN -o $IFACE -j TCPMSS --set-mss 1312
ip6tables -t mangle -A POSTROUTING -p tcp --tcp-flags SYN,RST SYN -o $IFACE -j TCPMSS --set-mss 1312
fi