vault backup: 2025-09-05 08:30:41
This commit is contained in:
parent
696cc81e2b
commit
894a381f6d
|
|
@ -13,6 +13,17 @@
|
|||
|
||||
### IPv4 forwarding
|
||||
|
||||
Host ports < 1024 as normal user and use iptables firewall to forward between localhost and public IP.
|
||||
|
||||
```
|
||||
/usr/sbin/iptables -F # flush all rules
|
||||
/usr/sbin/iptables -t nat -F # flush all nat rules
|
||||
/usr/sbin/iptables -X # Clear user defined chains
|
||||
/usr/sbin/iptables -t nat -A PREROUTING -p tcp --dport 80 -j DNAT --to 127.0.0.1:8080
|
||||
/usr/sbin/iptables -t nat -A POSTROUTING -j MASQUERADE
|
||||
/usr/sbin/iptables -t nat -L -v
|
||||
```
|
||||
|
||||
/etc/sysctl.conf:
|
||||
```
|
||||
net.ipv4.ip_forward = 1
|
||||
|
|
|
|||
Loading…
Reference in New Issue