Multi Sites Layout

If you have a dedicated server for your production, you probably know about virtual hosting.

The rules are pretty simple.

  • You need a domain or subdomain which points to the alahup install directory, in order to have access to the manager.

  • Each site's domain should point to the site's www directory.

  • In the site's config file (alahup/config/_config.prod.ini), the url should be set to the production url.

/usr/local/apache/httpd.conf :
...
# First define an access to the alahup manager.
# It will be reached at http://alahupmanager.mycompany.net/manager
 
<VirtualHost 213.186.37.174:80>
 DocumentRoot /home/alahup
 ServerName alahupmanager.mycompany.net
 <Directory "/home/alahup">
  Allow From All
 </Directory>
</VirtualHost>
 
# Define alahup web sites
 
<VirtualHost 213.186.37.174:80>
 DocumentRoot /home/alahup/sites/mywebsite/www
 ServerName www.mywebsite.net
 <Directory "/home/alahup/sites/mywebsite/www">
  Allow From All
 </Directory>
</VirtualHost>
 
<VirtualHost 213.186.37.174:80>
 DocumentRoot /home/alahup/sites/mywebsite2/www
 ServerName www.mywebsite2.net
 <Directory "/home/alahup/sites/mywebsite2/www">
  Allow From All
 </Directory>
</VirtualHost>
 ...