I'm trying to setup a corollary to how google asks people to point their subdomains to ghs.google.com which then presumably directs traffic to the right servers based on hostname.
My setup differs in that each subdomain will be hosted on a different VPS. I understand that I could give each person an individual VPS IP and ask them to point their cname to the actual address, but then I have to have the VPS setup before they do that. I'd like to give them something like ghs.google.com so that I can get them to point the cname before I setup the server and figure out the individual address.
If I understand correctly, my corollary of ghs.google.com would be a server that looks up the hostname and figures out the VPS address that is mapped to that hostname, and then act like a reverse proxy.
Assuming that my assumptions are correct, does anybody know what the best way to set this up is? Is there a better alternative than lighttpd?
Edit: It has been brought to my attention that this problem can be solved via DNS. If there is such a solution, can you elaborate?