wiki:WikiStart

CPS issue tracker

Welcome to the Collaborative Portal Server issue tracker. To create a ticket, you need to register and ask trac@… An alternative if you find it boresome is to log in as tracguest with password cps-cms. Don't forget to put your address in Cc, then. This more restrictive policy is due to a recent burst of spammers that get around reCaptcha. We'll try and find a better solution in the near future.

Starting Points

Mailing Lists

  •  CPS-Devel -- Discussion list for developers of CPS and CPS-related software
  •  CPS-Users -- Discussion and community support list for CPS users
  •  CPS-Users-FR -- Discussion and community support list for CPS users (French)
  •  Code -- Notifications of all code-related proceedings (ticket creations and updates, unit tests failures, code commits/checkins, etc.)

Instructions to prepare a development version of CPS

CPS is a set of Zope 2 products. each one being its own mercurial repository. To assemble these to form the Products directory expected by Zope, we use a dedicated tool: HgBundler.

This tool can actually be used to manage simultaneously any "bundle" of mercurial repositories. It's designed to replace and extend the what can be done with the svn:externals Subversion property.

CPS comes as three standard bundles which are themselves subdirectories of  a single repository:

  • CPS-3-base - the common set of products that almost all real world applications extend. CPSDefault is on top of the dependence hierarchy.
  • CPS-3 - CPS-3-base, together with the most common products outside of CPS-3-base
  • CPS-3-full - the full set of officially maintained components

All instructions and scripts mentioned on this page are meant for Unix-like systems and wouldn't work on Windows systems.

Automated process: mkcpsdevinstance

As of #2206, CPS comes with the mkcpsdevinstance script, that creates a Zope instance, sets up its Products directory as a HgBundler bundle and creates a CPS portal in it.

installation

Prerequisites:

  • all regular CPS dependencies
  • a working hgbundler on your path

Now, grab CPSUtil, extract mkcpsdevinstance and read the options list.

   $ hg clone http://hg.cps-cms.org/CPS/products/CPSUtil
   $ cp CPSUtil/bin/mkcpsdevinstance .
   $ ./mkcpsdevinstance --help

If you are running Debian (lenny or squeeze), or Ubuntu (10.04 LTS, 10.10) a useful alternative is to use our DebianPackages. To get a working mkcpsdevinstance in /opt/cps-3.5/bin, with all required dependencies, just do:

   $ sudo aptitude install opt-zope-cps-3.5-devsetup

Nota: Ubuntu 10.10 doesn't come with aptitude, either install it or use apt-get.

Usage

From now on, we assume that mkcpsdevinstance is on the system PATH.

To create a CPS-3-full instance in /var/opt:

   $ mkcpsdevinstance --zope-version=2.10 /var/opt/cps-3-full-dev 

Note that the script isn't that robust. You must check obvious things, such as write permission to create the target directory beforehand. Without the --zope-version option, the script will try /opt/Zope-2.10 first, and then /opt/Zope-2.9. These are the paths created by the Debian Squeeze packages.

The bundle URL for CPS-3-full is just the default value, one can get CPS-3-base by changing it:

   $ mkcpsdevinstance -b 'http://hg.cps-cms.org/CPS/bundles?subpath=CPS-3-base' --zope-bin=/opt/Zope-2.9/bin /var/opt/cps-3-base-dev 

One can use bundle branches as well, or custom bundles:

$ mkcpsdevinstance -b 'http://hg.cps-cms.org/CPS/bundles?subpath=CPS-3-full&branch=future-3.5.2' --zope-bin=/opt/Zope-2.9/bin /var/opt/cps-3-future-dev 
$ mkcpsdevinstance -b ssh://me@myproject.example.com/my_bundle --zope-bin=/opt/Zope-2.9/bin /var/opt/myproject-dev

Note that the subpath and branch parameters are specific of this script, they act as modifiers on what is otherwise a regular Mercurial URL.

Also, the branch parameter is simply passed as -r to hg update. Therefore it works also for tags or to pin a revision. For instance, to get a working CPS-3.5.1 (full) rig, just do (assuming the Zope install is in the default place, namely /opt/Zope-2.9):

$ mkcpsdevinstance -b 'http://hg.cps-cms.org/CPS/bundles?branch=3.5.1' /var/opt/cps-3-future-dev 

Manual process, from scratch

Here are the steps to get the CPS-3-full distribution with hgbundler on a Unix-like system.

$ hg clone http://hg.cps-cms.org/CPS/hgutils
$ cd hgutils
$ less hgutils/INSTALL.txt # you should do it, though the steps are below
$ python bootstrap.py
$ bin/buildout
$ bin/test # running the tests can help discovering mercurial version problems, etc.
$ cd ..
$ hg clone http://hg.cps-cms.org/CPS/bundles CPS-bundles
$ cd CPS-bundles/CPS-3-full
$ ../../hgutils/bin/hgbundler make-clones # of course it's better to put this on the path

Now move CPS-3-full as the Products of a Zope instance, or better, to refer to it in zope.conf, or make a symbolic link.

Edit the zope.conf of your instance and put the following settings:

    default-zpublisher-encoding utf-8

Wiki Starting Points