For me it seems that, a story for installing Plone with just pip is quite close (thanks to many things prior to this).
I did an example repository with the latest Plone requirements and minimal Plone instance skeleton
git clone https://github.com/datakurre/plone-pip
cd plone-pip
All required packages should install nicely with just pip install on a fresh Python 2.7 virtual env
virtualenv env
env/bin/pip install -U pip setuptools
env/bin/pip install -r requirements-5.1rc2.txt -r requirements.txt
I still required buildout to extracted those requirements using buildout.requirements from Plone 5.1.rc2-pending versions. In addition, I needed to
- Disable the default
z3c.autoinclude
and replace it with the branch withpip
compatibility. - Add my branch of
plonecli
that includes compatibleinstance
,zeoserver
andzeopack
scripts I extracted fromplone.recipe.zope2instance
andplone.recipe.zeoserver
.
In addition, the repository contains
-
./etc/site.zcml
, because currently Zope2 is hardcoded to loadsite.zcml
from{config.instancehome}/etc/site.zcml
(it would be easy fix into Zope2 to make that fully configurable) - minimal
./zope.conf
that configures$PWD
asinstancehome
and var (maybe not best practice, but simple for demo; also I could imagine creating custom zope.conf from bobtemplate usingplonecli
); also<includeDependencies />
directive (the evil twin of good<includePlugins />
) is disabled with an environment variable inzope.conf
After installation, Plone can be started in foreground with running a simple script for initializing the admin user and then starting the instance
env/bin/plonecli instance -C zope.conf run admin.py
env/bin/plonecli instance -C zope.conf fg
But that's just the start for the fun. Installing add-ons is simply pip install
and restarting the instance
env/bin/pip install collective.easyform
env/bin/pip install plone.app.imagecropping
And creating a new add-on is just an another call to plonecli
and python setup.py develop
to install the add-on into the virtualenv
source env/bin/activate
plonecli create addon my.addon
cd my.addon
python setup.py develop
I admit that pip may not ever replace existing professional buildout based development and deployment toolchains, but what are the reasonse why we shouldn't polish and promote this approach for new users?