Open Source Content Management System

Installing MidCOM with PEAR

  1. MidCOM installation
  2. Layout template installation
  3. Installing additional components

MidCOM releases from version 2.5 onwards have been shipped as PEAR packages for better version management and control. The packages utilize a MidCOM-specific channel in pear.midcom-project.org.

In Midgard 1.8 series and above the PEAR MidCOM installation is automatically performed by Datagard

MidCOM installation

  • Upgrade your PEAR installation. MidCOM installation requires PEAR 1.4 or newer.

    # pear upgrade PEAR
    

If it complains that you at least some version of PEAR to upgrade to the latest version install the requested version first with pear upgrade PEAR-<version>

  • Add the needed channels for package installation

    # pear channel-discover pearified.com
    # pear channel-discover pear.midcom-project.org
    
  • Install and configure the needed PEAR role files

    # pear install pearified/Role_Web
    # pear config-set web_dir /usr/share/midgard/midcom/static
    
    
    # pear install midcom/Role_Mgdschema
    # pear install midcom/Role_Midgardelement
    # pear install midcom/Role_Midgardsql
    
  • Install MidCOM and some required packages

    # pear install -f midcom/midcom
    

If you get a Fatal error: Allowed memory size exceeded error with any of the packages you have to increase PHP's memory limit. The file to edit is either /etc/php/php.ini or /etc/php/cli/php.ini. Memory limit is also settable with -d argument for php command ( php -d memory_limit=40M ).

Once you have installed new packages you need to stop and start Apache to get the MgdSchema files supplied with them loaded.

Layout template installation

Packaged layout templates utilize the Role_Midgardelement package for installation. To make installation work, you have to:

  • Create an unified Midgard configuration file to /etc/midgard/conf.d/midgard
  • Point the Midgardelement role to the configuration file

    # pear config-set midgard_config_file midgard
    
  • Install the style template you want, for example

    # pear install midcom/template_Kubrick
    

After these steps you should have a fully functional MidCOM installation in the PEAR path.

Installing additional components

Other component packages can be installed using the PEAR command, for example:

# pear install midcom/net_nehmer_blog

The list of available components can be found on the PEAR channel website

Designed by Nemein, hosted by Anykey