0

I have an application that is listening on a predefined port. I have configured it to use port 443, so that the user can just connect to a url.

Now I would like to have two instances of them running while still being available through the default port.

e.g.:

from example.com:443/one to example.com:30001
from example.com:443/two to example.com:30002

Is there a way (like reverse proxy) to set this up? And if so: is there a blog or tutorial I could follow through? I am fairly new to working with linux.

2
  • 1
    Yes, a reverse proxy is exactly the way to do it. Where are you stuck? Asking for learning material is off-topic. You can easily find dozens of guides using your favorite search engine.
    – Daniel B
    Dec 4, 2021 at 20:51
  • To be honest finding what I need was my problem! I'll look into proper ways to setup reverse proxys. Thank you for your help
    – HardReset
    Dec 4, 2021 at 20:56

1 Answer 1

0

A reverse proxy is one possible solution. To answer your second question, you can follow through this howto.

For that you would need for example an Apache installation with 1 virtual host listening to port 443. Then in the virtual host you would put something like:

ProxyPass "/one"  "https://example.com:30001/"
ProxyPassReverse "/one"  "https://example.com:30001/"
ProxyPass "/two"  "https://example.com:30002/"
ProxyPassReverse "/two"  "https://example.com:30002/"

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .