Open Source Content Management System

Creating a New Virtual Host

Type Virtual Host name in dialog box. There is no need (and you should not name your host with http:// or https:// protocol type). You may also define port which will be used for this virtual host. If your site is going to be served at port 80, you don't have to define the port. In any other case you should define the host with the port, like www.midgard-project.org:8001.

Congratulations! Your Midgard database and virtual host are now configured. *
Please, stop and start httpd now and log in to Midgard site.

  • In some cases the default virtual host configuration generated by Datagard is not correct or sufficient for your situation, for example when you are creating a SSL host or when you don't want the document root to change (datagard sets DocumentRoot under /var/lib/midgard/vhosts/ by default). You can edit the configuration manually in /etc/midgard/apache/vhosts/hostname_port. (Replace "hostname" with your virtual host name and "port" with the port of the virtual host. The port is 80 if you did not specify it.)

Some Midgard PHP applications depend on certain PHP settings. Here's a list of the needed PHP settings which should be set in the virtual host configuration (if not set in php.ini):

# Global virtual host level PHP settings for all Midgard applications  
#  
# Required for uploading attachments  
php_admin_flag file_uploads On  
# Required by majority of the Midgard PHP applications  
php_flag magic_quotes_gpc Off  
# Required by MidCOM <= 1.4 (comment this out with newer releases)  
php_flag short_open_tag On  
# Recommended at least for MidCOM AIS (8M is the minimum requirement)  
# (change and enable if you want to set different value than in php.ini)  
#php_value memory_limit 8M  
# Maximum size of POST data (affects attachment uploads)  
# (change and enable if you want to set different value than in php.ini)  
#php_value post_max_size 8M  
# Maximum size for uploaded files (affects attachment uploads)  
# (change and enable if you want to set different value than in php.ini)  
#php_value upload_max_filesize 2M  

# Location specific PHP settings for certain Midgard applications  
#  
<Location /spider-admin>  
 php_flag register_globals On  
</Location>  
<Location /aegir>  
 php_flag short_open_tag On  
 php_flag register_globals On  
</Location>

Once your VirtualHost is up and running you should be ready to set up the website using the Midgard Site Wizard.

If you need to later edit the configuration see Midgard Apache directives.

Designed by Nemein, hosted by Anykey