The setup I'm trying to create:
- a single physical dedicated server with a single public IP
- a number of hosted virtual machines (DomUs, with XEN) running Virtualmin (LAMP + other services), basically like a LAN with NAT
- HAProxy running on the physical server: it routes incoming connections to them on the right port, using hostnames
This works flawlessy with Apache on each VPS, but it doesn't seem to work with FTP/SSH/DNS: they don't use hostnames to discern which VPS has to be called.
Is there a way to accomplish this?
PS: I know I could run, for example, a single nameserver on the physical machine to serve DNS for all the domains hosted on the virtual machines, but my goal is to have these VPS autonomous, to be able to move them in the future without remembering which services are shared/bound with the hosting physical server.