Hello,
is there any way to configure DNAT, and SNAT to hosts via pve-firewall?
Currently we use for outgoing connections:
iptables -t nat -A POSTROUTING -s 192.168.64.0/24 -o vmbr0 -j SNAT --to-source 5.7.9.99
iptables -t nat -A POSTROUTING -s 192.168.80.102/32 -o vmbr0 -j SNAT --to-source 5.7.9.102
and for incoming connections:
iptables -t nat -A PREROUTING -d 5.7.9.102/32 -p tcp -m tcp --dport 443 -j DNAT --to-destination 192.168.80.102:443
iptables -t nat -A PREROUTING -d 5.7.9.101/32 -p tcp -m tcp --dport 443 -j DNAT --to-destination 192.168.80.101:443
But when restarting pve-firewall, these are lost.
Any help is appreciated.
Best regards
Thomas
is there any way to configure DNAT, and SNAT to hosts via pve-firewall?
Currently we use for outgoing connections:
iptables -t nat -A POSTROUTING -s 192.168.64.0/24 -o vmbr0 -j SNAT --to-source 5.7.9.99
iptables -t nat -A POSTROUTING -s 192.168.80.102/32 -o vmbr0 -j SNAT --to-source 5.7.9.102
and for incoming connections:
iptables -t nat -A PREROUTING -d 5.7.9.102/32 -p tcp -m tcp --dport 443 -j DNAT --to-destination 192.168.80.102:443
iptables -t nat -A PREROUTING -d 5.7.9.101/32 -p tcp -m tcp --dport 443 -j DNAT --to-destination 192.168.80.101:443
But when restarting pve-firewall, these are lost.
Any help is appreciated.
Best regards
Thomas