Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: apache2 virtualhosts subdomains |
|
Author |
|
disc
Joined: 03 Aug 2006 Posts: 3
|
Posted: Thu 03 Aug '06 2:57 Post subject: apache2 virtualhosts subdomains |
|
|
hey all,
first post...
I currently have apache2, php5, mysql5 running on my server 2003 box.
I have two domains running in virtual host configuration out of the httpd.conf file.
How would i go about adding subdomains to the already exsisting virtual hosts...
thanks for your help!! |
|
Back to top |
|
Steffen Moderator
Joined: 15 Oct 2005 Posts: 3092 Location: Hilversum, NL, EU
|
|
Back to top |
|
disc
Joined: 03 Aug 2006 Posts: 3
|
Posted: Thu 03 Aug '06 20:51 Post subject: |
|
|
i have two virtualhosts
mydomain1.com
mydomain2.com
both are virtual hosts....
i want to add subdomains to those domains
so ie:
mail.mydomain1.com goes to a subdirectory /mail on domain1.com
mail.mydomain2.com goes to sub /mail on domain2.com |
|
Back to top |
|
Steffen Moderator
Joined: 15 Oct 2005 Posts: 3092 Location: Hilversum, NL, EU
|
Posted: Thu 03 Aug '06 21:11 Post subject: |
|
|
Easiest is just make two vhost of the mail domains:
For example:
<VirtualHost *>
ServerName www.mydomain1.com
DocumentRoot c:/xxx/
</VirtualHost>
<VirtualHost *>
ServerName www.mydomain2.com
DocumentRoot c:/yyy/
</VirtualHost>
<VirtualHost *>
ServerName mail.mydomain1.com
DocumentRoot c:/xxx/mail
</VirtualHost>
<VirtualHost *>
ServerName mail.mydomain2.com
DocumentRoot c:/yyy/mail
</VirtualHost>
Steffen |
|
Back to top |
|
disc
Joined: 03 Aug 2006 Posts: 3
|
Posted: Thu 03 Aug '06 22:03 Post subject: |
|
|
thought so...
thanks a lot! |
|
Back to top |
|
|
|
|
|
|