[quote:ce7265e6db=”afriis”]I have over 20 (and counting) domains running on our webserver (Server 10.1). I would like to be able to use wildcards in the domain names to allow both “domainname.com” and “www.domainname.com” without resorting to adding two posts to the sites list in the Server admin for each domain. I tested this out using both blanks and “*” without sucess. Any tips?[/quote:ce7265e6db]
The simplest way to do this is to specify one name in Server Admin, and then edit [b:ce7265e6db]httpd_macosxserver.conf[/b:ce7265e6db] to add the other name as a [b:ce7265e6db]ServerAlias[/b:ce7265e6db].
For example, create the entry in Server Admin for “www.foobar.com” and then add[code:1:ce7265e6db]ServerAlias foobar.com[/code:1:ce7265e6db]right after the [b:ce7265e6db]ServerName[/b:ce7265e6db] line. Apple tried to discourage people from editing Apache configuration files in Server 10.1, but this small change won’t hurt Apache and will simplify your sites list in Server Admin.
I [i:ce7265e6db]think[/i:ce7265e6db] you might be able to achieve a similar effect by using wildcard DNS records, but am not certain. I know the directions above work, as I used them myself.
Comments are closed