0

I have a http service running on localhost port 8080 on a centos 7 machine. Is there any way I can route / port forward incoming and outgoing traffic through my external interface. So, mapping 127.0.0.1:8080 to <my external ip address>:8080?

I'd also like to do the same with https if possible as well.

I don't have access to the application code, so would prefer an iptables / port forwarding solution if possible.

1 Answers1

0

The REDIRECT target is probably the answer:

https://www.frozentux.net/iptables-tutorial/iptables-tutorial.html#REDIRECTTARGET

Dylan
  • 510