[buildout]

extends =
  ../../component/git/buildout.cfg
  ../../stack/lapp/buildout.cfg


# += since we need rdiff-backup and friends
parts +=
  apache-php-postgres
  pear-modules
  eggs
  instance
  instance-apache-php

[versions]
slapos.recipe.maarch = 0.3


#----------------
#--
#-- Main application part
#--

[application]
url = http://downloads.sourceforge.net/project/maarch/Maarch%20Entreprise/MaarchEntreprise-1.3.zip
md5sum = 5c2c859dee9d0dde3ba959474fd5fc86


#----------------
#--
#-- Define parts that will be executed later, in the instance.
#--

[custom-application-deployment]
path = ${custom-application-deployment-template:output}
part-list = maarch-configuration

[custom-application-deployment-template]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-custom.cfg.in
output = ${buildout:directory}/instance-custom.cfg
md5sum = f86b311d443156e327a1b5f5acfb22b1
mode = 0644


#----------------
#--
#-- Install PHP channels and modules (only if they are not already installed).
#--

[pear-modules]
recipe = cp.recipe.cmd
pear = ${apache-php-postgres:location}/bin/pear
install_cmd =
    ${:pear} channel-info pear.maarch.org >/dev/null || ${:pear} channel-discover pear.maarch.org
    ${:pear} info maarch/CLITools-0.3.1 >/dev/null || ${:pear} install maarch/CLITools-0.3.1
    ${:pear} info MIME_Type >/dev/null || ${:pear} install MIME_Type


#----------------