Many times there is a need to publish multiple websites from internal network, but there is only one public IP address available.

How this can be done easy way? HAProxy can help us with it.

In example configuration I have 2 URLs registered to same public IP address:

  • first.laboratory.net
  • second.laboratory.net
  • third.laboratory.net

Here is how HAProxy configuration for given example looks like…

(more…)