What I try to achive is a simple domain pointing to example I have
www.domain.tdl
and supply to the users
username.domain.tdl
which works great.
But as soon as I want to enable a domain pointing (they create a CNAME entry on there own domain to the subdomain) I would have to setup a record for each domain in the webserver and restart it after.
How would I achieve such a construct with Apache?
And what’s the best way of doing that?
The best example for that is probably Google Mail: you can get mail.yourdomain.tl
If a domain points to it which isn’t defined in the vhosts it will automatically use the first vhost.
So if you make sure the website is the first vhost it will automically work.