Skip to content

Instantly share code, notes, and snippets.

@fernyb
Created March 16, 2013 00:19
Show Gist options
  • Save fernyb/5174248 to your computer and use it in GitHub Desktop.
Save fernyb/5174248 to your computer and use it in GitHub Desktop.
redirect port
--iptables -A INPUT -i eth0 -p tcp --dport 80 -j ACCEPT
--iptables -A INPUT -i eth0 -p tcp --dport 8080 -j ACCEPT
--iptables -A PREROUTING -t nat -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment