Skip to content

Instantly share code, notes, and snippets.

@antonga23
Forked from debashisbarman/forwardport.sh
Created November 18, 2020 19:32
Show Gist options
  • Save antonga23/62750dc35bf3fbc0017428105011bf3c to your computer and use it in GitHub Desktop.
Save antonga23/62750dc35bf3fbc0017428105011bf3c to your computer and use it in GitHub Desktop.
Forward port 80 to 8080 on EC2 instance.
sudo iptables -t nat -L
sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment