Forward based on hostname

  • Hi,

    Sorry if this has been covered - I have been looking through the forums for awhile because it seems like it should be a common request.

    I would like to get a number of web servers running on my internal network (NAT).  But only have a single public IP address for my WAN interface.

    If a external user requets "" I would like to get it to port 80 on "server1" and if they type in "" have it forward to port 80 on "server2" and so on.  From the NAT menu I can only see how to do this using different ports - ie. server1 on TCP-80 and server2 on TCP-8080.  To complicate things a bit I also have some Apache servers running Virtual Hosts (based on hostname).

    My DNS is setup to point all A records to the public (WAN) IP address.

    Again - sorry if this has been covered.



  • Pfsense can't do this. You would have to work this out with apache. Either put all the websites on the same server, or I think you could use the apache proxy module to grab the pages and from the correct server and act as the middleman.

  • Thank you for the quick reply.

    I think I will just install Pound ( at a central point and forward all web traffic to it for redistribution based on requested URL.

    Again - thank you for the quick reply :-)

    If I ever learn how to create packages I will attempt a pound package.



Log in to reply