Lets say you just had to register imadork.com. What do you do?
Basic Overview
- Register it w/ your favorite registrar. (anything but verisign!)
- Add it to your Apache setup and restart apache.
- Add it to your DNS setup and HUP named.
- Add it to your qmail setup and restart qmail.
Details
Registrars
I will not discuss registering your domain. If you can’t figure that out, then you have other problems. I suggest dotster.
Apache
These notes will be slightly specific to my apache setup, but should be applicable with minor modifications. For example, I have each domain setup under conf/domains and have apache include every file in that directory. This allows various domain owners to tweak their own configs.
- Run:
- cd ~www
- sudo mkdir -p imadork.com/{analog,analog_data,html,logs}
- ln -s zenspider.com/bin imadork.com
- cp conf/domain/existing.com conf/domain/imadork.com
-
Edit new domain config file (or section in httpd.conf) with the following templated information:
<VirtualHost *> # basic info from template above: ServerAdmin owner@imadork.com DocumentRoot /usr/home/www/imadork.com/html ServerName www.imadork.com ErrorLog /usr/home/www/imadork.com/logs/error.log CustomLog /usr/home/www/imadork.com/logs/access.log combined
# anything below here is extra set by ryand: ServerAlias imadork.com *.imadork.com <Directory "/usr/home/www/imadork.com/analog/"> Options +Indexes </Directory></VirtualHost>
- Run:
- apache configtest
- apache restart
DNS/BIND
Setup is specific to zenspider.com. I will try to document it in another page soon. (TODO)
- Run:
- cd /etc/named
- Edit GNUmakefile and add imadork.com to DOMAIN variable.
- Edit named.conf to include dns.imadork.com as a master domain.
- sudo gmake
- sudo killall -HUP named
-
named.conf should look like:
zone “imadork.com” { type master; file “dns.imadork.com”;
};
Finally, contact your secondary DNS provider and make sure he adds the new domain as a slave into his/her setup and restarts.
Qmail
- Run:
- cd /var/qmail/control
- Edit rcpthosts and virtualdomains as described below.
- sudo killall qmail-lspawn
- sudo killall tcpcontrol
-
ps auxww egrep “(qmail splogger)” - sudo /usr/local/etc/rc.d/qmail.sh
- sudo /usr/local/etc/rc.d/tcpcontrol.sh
TODO: check above list and make sure setup is correct.
-
rcpthosts:
imadork.com .imadork.com
-
virtualdomains:
imadork.com:username
Requirements:
- Qmail 1.0.3 or better. Probably older versions as well.
- BIND 8.3.1 or better. Probably older versions as well.
Compatibility
Should work w/ qmail and bind on any system.
Code
N/A
Crontab
N/A