Hi all i want to ask how is it possible to serve multiple sites hosted in my computer with apache through dyndns.I am using ubuntu 10.04 and i had setup a dyndns domain as of mydomain.homelinux.org/ .Also i had setup a virtual host with the below configuration
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName www.drupal-site.com
ServerAlias drupal-site.com
DocumentRoot /home/pavlos/Temp/websites/drupal-site/htdocs
<Directory />
Options FollowSymLinks
AllowOverride all
</Directory>
<Directory /home/pavlos/Temp/websites/drupal-site/htdocs/>
Options FollowSymLinks
AllowOverride all
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /home/pavlos/Temp/websites/drupal-site/cgi-bin/
<Location /cgi-bin>
Options +ExecCGI
</Location>
# Logfiles
ErrorLog /home/pavlos/Temp/websites/drupal-site/logs/error.log
CustomLog /home/pavlos/Temp/websites/drupal-site/logs/access.log combined
</VirtualHost>
My /etc/hosts file is:
127.0.0.1 localhost joomla-site.com drupal-site.com
127.0.1.1 medic
Now when i go to mydomain.homelinux.org outside of my lani see the default site of apache.Any suggestions?
-
You would want to have domains like:
www.joomla-site.com and joomla-site.com set up with a CNAME to mydomain.homelinux.org and the same with www.drupal-site.com and drupal-site.com.
That way, when the person requests www.joomla-site.com, the Host header passed to apache is correct, rather than you seeing mydomain.homelinux.org.
You can do the same with an A record, but, a CNAME would not require you to configure the domains with an IP address, and when your dynamic DNS address is updated, your other two domains wouldn't need any DNS changes.
From karmawhore
0 comments:
Post a Comment