Install Plone 6 classic UI with PDM

PDM is a modern Python package manager, which can install Plone and it's dependencies and keep it consistent. I have setup an example repository everyone can use to setup Plone with PDM. It supports both simple standalone and RelStorage setups.

checkout this repository like this:

git clone plone6classicui
cd plone6classicui

creating a venv:

python3.11 -m venv venv

installing PDM with pip:

./venv/bin/pip install pdm

add needed Plone Add-on's in the pyproject.toml:

dependencies = [
    ### only needed when using relstorage

Install Plone and all dependencies:

./venv/bin/pdm install

Standalone setup

Create a Zope instance:

./venv/bin/pdm run instance_create

Adjust the instance port in instance1/etc/zope.ini

use = egg:waitress#main
host =
port = 8080

RelStorage setup

Alternatively you can also create a RelStorage setup like this:

./venv/bin/pdm run create_relstorage_instance

Adjust the data base connection string in instance1/etc/zope.conf:

<zodb_db main>
    blob-dir $INSTANCE/var/blobstorage
        dsn dbname='my_plone_database' user='my_plone_db_user' host='localhost' password='SECRET'
mount-point /

Start the instance

./venv/bin/pdm run instance_start

In production you want to add this to something like supervisor or a systemd script.

By @MrTango in
Tags :