Domain aliases and SERVER_NAME
Posted by: Cuvou
Posted on: 2007-01-13 12:17:00
Hi, I'm thinking about switching to dreamhost to host my personal website. Here is how I currently have them set up:
I have the domains
cuvou.com
cuvou.net
cuvou.org
All of their DNS settings are mostly identical. They all have an A record pointing to my server IP address, which is really just a PC on my network. The server itself (Apache) serves the same DocumentRoot for all the domain names, such that "cuvou.com/files" and "cuvou.org/files" goes to the exact same place.
The website itself is CGI-based (a "/index.cgi"), and the CGI behaves slightly different based on which website the user is on. So, cuvou.org has a different navigation bar than does cuvou.net, which has a different navigation bar than cuvou.com, even though all three domains are requesting the exact same file from the exact same place on my server.
The CGI uses the environment variable SERVER_NAME to distinguish which domain you're viewing the page from.
So, my main question is: does DreamHost support this kind of a system, to where multiple domain names can have the same DocumentRoot?
The second question is: does DreamHost allow the execution of Perl code from outside of the cgi-bin? As I mentioned, my index page is CGI which is served from "/index.cgi" and not from a "/cgi-bin", so this is important too.
Also, cuvou.net has an MX record pointing to Windows Live Domains, and I have a few members who have @cuvou.net e-mail addresses hosted with Hotmail. Will DreamHost allow me to keep the MX record pointing to Hotmail?
If these things will work here, I plan to host my site here. :)