progress on Zope 2.12.0a1 from buildout with no funky recipes ; -)
Hey All, I've made some progress on this, here's the buildout: [buildout] parts = zopeinstance extends = versions2.cfg [zopeinstance] recipe = zc.recipe.egg eggs = zope2 entry-points= runzope=Zope2.Startup.run:run zopectl=Zope2.Startup.zopectl:main scripts = runzope zopectl initialization = import sys sys.argv[1:1] = ['-C','${buildout:directory}/etc/zope.conf'] There are 3 other files you need: - versions2.cfg, which is a static copy of: http://svn.zope.org/*checkout*/Zope/tags/2.12.0a1/versions-zope2.cfg (and changed to extend versions3.cfg instead of versions-zope3.cfg) - versions3.cfg, which is a static copy of: http://svn.zope.org/*checkout*/Zope/tags/2.12.0a1/versions-zope3.cfg - zope.conf, which is a minimal zope.conf So, with this, the following will work: - bin/runzope - bin/zopectl fg However, bin/zopectl (start|stop) doesn't work because line 131 of zopectl.py sets zdrun to a hard coded path. I guess we need to generate a script for zdrun that has all the eggs present. Any ideas on the "right" way to do this? I guess we may need to do something similar with zeoctl? cheers, Chris
Hi, Well, I made some progress in that ZEO instances are just fine to get going. Here's the buildout.cfg: [buildout] parts = zeoinstance extends = versions2.cfg [zeoinstance] recipe = zc.recipe.egg eggs = ZODB3 entry-points= runzeo=ZEO.runzeo:main zeoctl=ZEO.zeoctl:main zdrun=zdaemon.zdrun:main scripts = runzeo zeoctl zdrun initialization = import sys sys.argv[1:1] = ['-C','${buildout:directory}/etc/zeo.conf'] ... with versions2.cfg and versions3.cfg coming from the same source as my previous zope instance attempt, and here's the zeo.conf: %define INSTANCE . <zeo> address 2000 </zeo> <filestorage 1> path $INSTANCE/var/Data.fs </filestorage> <eventlog> level info <logfile> path $INSTANCE/log/zeo.log </logfile> </eventlog> <runner> program $INSTANCE/bin/runzeo daemon true forever false backoff-limit 10 exit-codes 0, 2 directory $INSTANCE default-to-interactive true zdrun $INSTANCE/bin/zdrun logfile $INSTANCE/log/zdrun.log </runner> Now, one question I had was how to get $INSTANCE to be set to where the buildout.cfg is, rather than having it hardcoded to '.'? '.' works just fine, provided you run the control scripts from within the buildout directory, but I don't know how to do that from cron. So, two ideas: - can ZConfig take stuff from the environment? (who maintains ZConfig now?) - Hanno, what was that stuff you mentioned? cheers, Chris
participants (1)
-
Chris Withers