utdiscant
utdiscant

Reputation: 11542

Simple forwarding of traffic on specific port to localhost on Amazon EC2

I have an Amazon EC2 instance running. I want to forward any incoming traffic on port 8000 to http://localhost:8000 where I have a Flask server listening. What is the easiest way to do this?

Upvotes: 0

Views: 252

Answers (1)

Greg Szymanski
Greg Szymanski

Reputation: 336

You can configure nginx proxy or haproxy to achieve that. There are many good tutorials available on Internet. If you want to use it for development purpose, you can run Flask on 0.0.0.0 instead of localhost.

Upvotes: 1

Related Questions