0

How to i setup DNS and Web so that Mac OS X Server 10.6 displays a webpage under http://domain.net instead of http://www.domain.net

www is fast becoming deprecated with people forgetting to add it. Some browsers add it and some don't.

How do i do this?

unom
  • 281
  • 5
  • 13

2 Answers2

1

Basically you neeed to have

  1. Dns records for www.domain.net and domain.net to point your server
  2. You need to have (i assume apache is default on mac server) on your virtualhost config/section also DomainAlias.

    ServerAdmin admin@domain.net
    
    ServerName domain.net
    
    ServerAlias www.domain.net domain.com www.domain.com
    
    DocumentRoot /home/sivu/public
    

That way your server will hand over site were it requested with or without www.

Not sure where you can actually manage configuration on mac os x server. If you have default configuration (this site is (maybe only) default site). Then you don't have to do anything else than #1. In linux environment those config files can be found from /etc/apache2/sites-available. Mac prob have some control-panel for this.

eXlin
  • 36
  • 1
0

I suggest taking a look at these similar questions.

Nic
  • 13,025
  • 16
  • 59
  • 102
  • I want to have it the other way around. I want the www domains to point to the empty root domain. – unom Feb 13 '11 at 11:19
  • Regardless of which canonical form you prefer, you use the same techniques to enforce it. – Nic Feb 14 '11 at 07:38