Attention

This document was written for an old version of Plone, Plone 3, and was last updated 750 days ago.

To learn how to upgrade to the current version of Plone, read the upgrade manual.

Setup Plone & configure Buildout

by Bryan Hinton last modified May 03, 2010 07:05 PM
Create & Configure Plone instance via zc.buildout (updated for Plone 3.3.5)

Plone 3 Buildout

# cd /usr/local/plone
# paster create -t plone3_buildout mydomain.com
# cd mydomain.com
# python2.4 bootstrap.py
# mkdir /usr/local/plone/mydomain-buildout-cache
# mkdir /usr/local/plone/mydomain-buildout-cache/eggs
# mkdir /usr/local/plone/mydomain-buildout-cache/downloads
# chown -R zadmin:www

buildout.cfg

[buildout]
eggs-directory=/usr/local/plone/mydomain-buildout-cache/eggs
download-cache=/usr/local/plone/mydomain-buildout-cache/downloads

parts =
    zope2
    productdistros
    client1
    zeoserver
    zopepy
    squid-build
    squid-instance

# Change the number here to change the version of Plone being used
extends = 
    http://dist.plone.org/release/3.3.5/versions.cfg
versions = versions

# Add additional egg download sources here. dist.plone.org contains archives
# of Plone packages.
find-links =
    http://dist.plone.org/release/3.3.5
    http://dist.plone.org/thirdparty
    http://dist.plone.org
    http://download.zope.org/ppix/
    http://download.zope.org/distribution/
    http://effbot.org/downloads

# Add additional eggs here
eggs = 
    Products.DocFinderTab
    Products.CacheSetup

# Reference any eggs you are developing here, one per line
# e.g.: develop = src/my.package
develop =

[zope2]
# For more information on this step and configuration options see:
# http://pypi.python.org/pypi/plone.recipe.zope2install
recipe = plone.recipe.zope2install
fake-zope-eggs = true
url = ${versions:zope2-url}

additional-fake-eggs = 
    ZConfig
    pytz

# Use this section to download additional old-style products.
# List any number of URLs for product tarballs under URLs (separate
# with whitespace, or break over several lines, with subsequent lines
# indented). If any archives contain several products inside a top-level
# directory, list the archive file name (i.e. the last part of the URL,
# normally with a .tar.gz suffix or similar) under 'nested-packages'.
# If any archives extract to a product directory with a version suffix, list
# the archive name under 'version-suffix-packages'.
[productdistros]
# For more information on this step and configuration options see:
# http://pypi.python.org/pypi/plone.recipe.distros
recipe = plone.recipe.distros
urls =
nested-packages =
version-suffix-packages =

[zeoserver]
recipe = plone.recipe.zope2zeoserver
zope2-location = ${zope2:location}
zeo-address = 127.0.0.1:8900
effective-user = zadmin

[client1]
# For more information on this step and configuration options see:
# http://pypi.python.org/pypi/plone.recipe.zope2instance
recipe = plone.recipe.zope2instance
zope2-location = ${zope2:location}
zeo-client = true
zeo-address = ${zeoserver:zeo-address}
zodb-cache-size = 5000
zeo-client-cache-size = 300MB
user = admin:mysecretpassphrase
effective-user = zadmin
http-address = 127.0.0.1:8901
debug-mode = off
verbose-security = off

# If you want Zope to know about any additional eggs, list them here.
# This should include any development eggs you listed in develop-eggs above,
# e.g. eggs = Plone my.package
eggs =
    Plone
    ${buildout:eggs}

# If you want to register ZCML slugs for any packages, list them here.
# e.g. zcml = my.package my.other.package
zcml =

products =
    ${buildout:directory}/products
    ${productdistros:location}

[zopepy]
# For more information on this step and configuration options see:
# http://pypi.python.org/pypi/zc.recipe.egg
recipe = zc.recipe.egg
eggs = ${client1:eggs}
interpreter = zopepy
extra-paths = ${zope2:location}/lib/python
scripts = zopepy

[squid-build]
recipe = plone.recipe.squid:build
url = http://www.squid-cache.org/Versions/v2/2.7/squid-2.7.STABLE9.tar.gz

[squid-instance]
recipe = plone.recipe.squid:instance
bind = 127.0.0.1:8902
backends = 127.0.0.1:8901
cache-size = 1G
user = zadmin
group = www
# ./bin/buildout
# chown -R zadmin:www ../mydomain.com*
# ./bin/zeoserver start
# ./bin/client1 start

 

If your server is remote, then perform the following from the client (desktop computer):

ssh -f user@mydomain.com -L 8901:localhost:8901 -N

Now open a browser window and go to http://localhost:8901/manage

  1. login as admin with mysecretpassphrase (the passphrase you put in buildout.cfg) as the password
  2. go to the top right of the screen and click on the drop down menu.
  3. select add and then choose plone site
  4. set the ID to Plone
  5. click on  portal_quickinstaller which will be on the left under your new plone site
  6. install CacheSetup
  7. install any other Products that you may need
  8. you can close the ssh connection now

Contribute

Something wrong or out of date? Anybody can edit or create a new article in the knowledge base. Simply create an account on this site, log in, and click the Edit button to contribute.