How to permanently enable IPv4 forwarding in Alpine Linux

This simple command will permanently enable IPv4 forwarding on Alpine Linux. Run this as root:

enable_ipv4_forwarding.sh
echo net.ipv4.ip_forward=1 | tee -a /etc/sysctl.conf && sysctl -p

 


Check out similar posts by category: Alpine Linux, Networking