many third level domains bind & apache (slightly off topic)

Kelsey Cummings kc at neteze.com
Fri Sep 24 23:55:29 UTC 1999


I've got a customer who wants to sell third level domains with small virtual
webs and one email account.  I've agreed to do it, but I'm trying to figure
out the best way to provide him this service.

Its unfortunate that bind doesn't support wildcards in A records (it doesn't
right?) otherwise DNS configuration would be very simple.  As far as I can
tell apache doesn't have an way of doing regex matching in the configs (at
least as would be needed for this setup)  ie:

*.hisdomain.com    IN    A        www.hisdomain.com

-->  Has someone hacked bind to support this?

<virtual host $1.hisdomain.com>
        ServerName $1.hisdomain.com
        DocumentRoot /usr/home/user/www/$1
</VirtualHost>

That would just be too easy.  :(

Has anyone setup something similar?  How did you do it?

Also --  If I setup a large number of virtual hosts in this manner (he's
talking about 300 or so)  I'd like to point all of his virtual hosts logs to
the same file::  does this work or cause corruption of the logs?  The only
other way I could think of accomplishing it would be to run a seperate httpd
for him, where the logs for the virtual host would be inherited from the
main server, correct?

<virtual host 1.hisdomain.com>
        ServerName 1.hisdomain.com
        DocumentRoot /usr/home/user/www/1
        CustomLog usr/home/user/access-log combined
</VirtualHost>

<virtual host 2hisdomain.com>
        ServerName 2hisdomain.com
        DocumentRoot /usr/home/user/www/2
        CustomLog /usr/home/user/access-log combined
</VirtualHost>


Hope this makes some sense.   Thanks in advance.

-----------------------------------------------------------------
Kelsey Cummings
System Administrator
NetEase, Inc.
kc at neteze.com
-----------------------------------------------------------------



More information about the bind-users mailing list