redirect by host_header
I am trying to figure out how I can receive multiple requests to the same ip address and redirect to different servers based off the host_header... Let me give you an example of what I am trying to do:
host to IP:
host1.routeme.com --> 22.214.171.124 (WAN IP)
host2.routeme.com --> 126.96.36.199 (WAN IP)
188.8.131.52 looks at host_header then performs the following:
If host_header = host1.routeme.com redirect to local ip 192.168.0.21 (LAN IP)
If host_header = host2.routeme.com redirect to local ip 192.168.0.22 (LAN IP)
I was thinking that I might have to use a proxy but I cant find one that will redirect using a host_header instead of an IP.
Maybe I am thinking about this the wrong way... Help.