0

I have two http servers (Apache Tomcat [192.168.1.5:8080] and Jetty [192.168.1.55:9090]) behind the router (Linux [192.168.1.200], iptables). I also have a public domain: domain.net.

My question: How to redirect

sub1.domain.net to server1 (192.168.1.5:8080/app1)

and

sub2.domain.net to server2 (192.168.1.55:9090/app2)

?

I tried to redirect using iptables, but it can forward only ip addresses (even I write FQDN it first translate it into IP address and then transfer). I also heard about squid, but maybe I do sth wrong with redirection because squid can redirect request using FQDN but address in browser is changed - I need this address not to be changed.

Cœur
  • 37,241
  • 25
  • 195
  • 267

1 Answers1

0

You could use a single "frontal server" with Apache, which would be proxifying to different servers on your LAN based on the FQDN, but that's just a suggestion :)