I currently have a structure with an Apache 2 server with multiple subdomains. As the example below:
<VirtualHost *:80>
ServerName www.example.com
ServerAlias example.com
DocumentRoot /var/www/main
</VirtualHost>
<VirtualHost *:80>
ServerName subdomain-1.example.com
ServerAlias subdomain-1.example.com
DocumentRoot /var/www/sbd1
</VirtualHost>
<VirtualHost *:80>
ServerName subdomain-2.example.com
ServerAlias subdomain-2.example.com
DocumentRoot /var/www/sbd2
</VirtualHost>
I am considering duplicating this server and just creating a new one with HAProxy to perform load balancing.
Does HAProxy support point all requests to the child server with the same IP or for each subdomain will I need specific server with a specific IP?