; This configuration installs a cluster [buildout] extends = base.cfg parts += apacheconfig haproxy zeo_server zeo_client_1 zeo_client_2 cluster parts -= erp5_instance [apachebuild] recipe = plone.recipe.apache:build url = http://apache.multidist.com/httpd/httpd-2.2.11.tar.gz modules = mod_cache mod_mpm mod_proxy mod_deflate mod_conf mod_base mod_modules mod_disk_cache mod_ssl mod_htcacheclean [apacheconfig] recipe = plone.recipe.apache:config mainconfig = ${apachebuild:location}/conf/httpd.conf bind = 443 zope2_vhm_map = localhost:/erp5 backends = localhost:127.0.0.1:2002 [haproxy] recipe = plone.recipe.haproxy url = http://haproxy.1wt.eu/download/1.3/src/haproxy-1.3.15.7.tar.gz target = linux26 [haproxy_etc_folder] recipe = ore.recipe.fs:mkdir path = ${haproxy:location}/etc [haproxyconfig] recipe = buildout_script:template template = haproxy.cfg.default output_dir = ${haproxy:location}/etc maxconn = 2000 retries = 3 port = 2002 balance = roundrobin rules = server zeo_client_1 127.0.0.1:${zeo_client_1:http-address} cookie zeo_client_1 check inter 3s rise 2 fall 4 maxconn 1 server zeo_client_2 127.0.0.1:${zeo_client_2:http-address} cookie zeo_client_2 check inter 3s rise 2 fall 4 maxconn 1 httpchk = /erp5/getId [zeo_server] recipe = plone.recipe.zope2zeoserver zope2-location = ${zope2:location} user = ${erp5_instance:user} zeo-address = 8100 eggs = ${erp5_instance:eggs} [zeo_client_1] recipe = plone.recipe.zope2instance zope2-location = ${zope2:location} user = ${zeo_server:user} http-address = 18180 debug-mode = off zeo-client = on zeo-address = ${zeo_server:zeo-address} control-script = zopectl-zeo_client_1 eggs = ${erp5_instance:eggs} products = ${erp5_instance:products} zope-conf-additional = ${erp5_instance:zope-conf-additional} [zeo_client_2] recipe = plone.recipe.zope2instance zope2-location = ${zope2:location} user = ${zeo_server:user} http-address = 18280 debug-mode = off zeo-client = on zeo-address = ${zeo_server:zeo-address} control-script = zopectl-zeo_client_2 eggs = ${erp5_instance:eggs} products = ${erp5_instance:products} zope-conf-additional = ${erp5_instance:zope-conf-additional} [cluster] recipe = plone.recipe.cluster start = ${buildout:bin-directory}/zeo_server start ${buildout:bin-directory}/zopectl-zeo_client_1 start ${buildout:bin-directory}/zopectl-zeo_client_2 start stop = ${buildout:bin-directory}/zeo_server stop ${buildout:bin-directory}/zopectl-zeo_client_1 stop ${buildout:bin-directory}/zopectl-zeo_client_2 stop restart = ${buildout:bin-directory}/zeo_server restart ${buildout:bin-directory}/zopectl-zeo_client_1 restart ${buildout:bin-directory}/zopectl-zeo_client_2 restart