From 005cf6b3d0bf8bae357fb32993f66c6a1a696e64 Mon Sep 17 00:00:00 2001
From: Kazuhiko Shiozaki <kazuhiko@nexedi.com>
Date: Thu, 9 Dec 2010 10:09:59 +0000
Subject: [PATCH] good-bye erp5.recipe.standalone. use
 erp5.recipe.zope2instance instead.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@41256 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 buildout/instance-profiles/zope-2.12.cfg | 87 +++---------------------
 buildout/instance-profiles/zope.cfg      | 87 +++---------------------
 buildout/profiles/versions-2.12.cfg      |  3 +
 buildout/profiles/versions-common.cfg    |  1 -
 buildout/profiles/versions.cfg           |  8 ++-
 buildout/software-profiles/erp5-2.12.cfg |  2 +-
 buildout/software-profiles/erp5.cfg      |  3 +-
 7 files changed, 29 insertions(+), 162 deletions(-)

diff --git a/buildout/instance-profiles/zope-2.12.cfg b/buildout/instance-profiles/zope-2.12.cfg
index 6fb126d34e..d91a658812 100644
--- a/buildout/instance-profiles/zope-2.12.cfg
+++ b/buildout/instance-profiles/zope-2.12.cfg
@@ -3,82 +3,13 @@
 parts = zope-instance
 
 [zope-instance-template]
-recipe = erp5.recipe.standaloneinstance
+recipe = erp5.recipe.zope2instance
 user = zope:zope
-
-# empty bt5 by default
-bt5 =
-bt5-path =
-
-# modify this to reflect your local mysql configuration
-# Format:
-#     database[@host[:port]] [user [password [unix_socket]]]
-#   e.g "erp5db erp5user somepassword" or "erp5db erp5user"
-erp5_sql_connection_string = ${:mysql_database_name}@${:mysql_host}:${:mysql_port} ${:mysql_user} ${:mysql_password}
-
-zope_conf_template =
-  ${software_definition:software_home}/parts/erp5-zope2.12-template/template.in
-
-portal_id = erp5
-force-zodb-update = false
-# zope.conf template part BEGIN
-# instancehome and http-address have to be defined
-# User modifable keys:
-environment =
-  <environment>
-    PATH ${software_definition:software_home}/parts/imagemagick/bin:${software_definition:software_home}/parts/w3m/bin:${software_definition:software_home}/parts/xpdf/bin:${software_definition:software_home}/parts/ghostscript/bin:${software_definition:software_home}/parts/pdftk/bin:${software_definition:software_home}/parts/file/bin:${software_definition:software_home}/parts/graphviz/bin
-  </environment>
-debug-mode = off
-ip-address = 0.0.0.0
-# Good defaults, which do not have to be touched:
-clienthome = ${:instancehome}/var
-lib_path = ${:instancehome}/lib/python
-effective-user =
-enable-product-installation = on
-locale =
-datetime-format = us
-zserver-threads = 4
-python-check-interval = 500
-zserver-read-only-mode = off
-pid-filename = ${:clienthome}/Z2.pid
-lock-filename = ${:clienthome}/Z2.lock
-mime-types =
-structured-text-header-level = 3
-rest-input-encoding =
-rest-output-encoding =
-rest-header-level = 3
-rest-language-code = en
-cgi-environment =
-dns-server =
-http-realm = Zope
-cgi-maxlen = 0
-http-header-max-length = 8192
-automatically-quote-dtml-request-data = on
-trusted-proxy =
-publisher-profile-file =
-security-policy-implementation = C
-skip-authentication-checking = off
-skip-ownership-checking = on
-verbose-security = off
-maximum-number-of-session-objects = 1000
-session-add-notify-script-path =
-session-delete-notify-script-path =
-session-timeout-minutes = 20
-session-resolution-seconds = 20
-suppress-all-access-rules = off
-suppress-all-site-roots = off
-database-quota-size =
-read-only-database = off
-eventlog-level = info
-eventlog-path = ${:instancehome}/log/event.log
-access-level = WARN
-access-path = ${:instancehome}/log/Z2.log
-access-format = %(message)s
-warnfilter =
-max-listen-sockets = 100
-port-base = 0
-large-file-threshold =
-default-zpublisher-encoding = utf8
-http-force-connection-close = off
-zodb-path = ${:instancehome}/var/Data.fs
-# zope.conf template part ENDS
+environment-vars =
+  PATH ${software_definition:software_home}/parts/imagemagick/bin:${software_definition:software_home}/parts/w3m/bin:${software_definition:software_home}/parts/xpdf/bin:${software_definition:software_home}/parts/ghostscript/bin:${software_definition:software_home}/parts/pdftk/bin:${software_definition:software_home}/parts/file/bin:${software_definition:software_home}/parts/graphviz/bin
+zope-conf-additional =
+  # Use the clock-server to trigger the TimerService
+  <clock-server>
+    method /Control_Panel/timer_service/process_timer?interval:int=5
+    period 5
+  </clock-server>
diff --git a/buildout/instance-profiles/zope.cfg b/buildout/instance-profiles/zope.cfg
index e63aa01124..0753f4a02d 100644
--- a/buildout/instance-profiles/zope.cfg
+++ b/buildout/instance-profiles/zope.cfg
@@ -2,83 +2,14 @@
 # be instaciated by another recipe.
 
 [zope-instance-template]
-recipe = erp5.recipe.standaloneinstance
+recipe = erp5.recipe.zope2instance
 zope2-location = ${software_definition:zope_software}
 user = zope:zope
-
-# empty bt5 by default
-bt5 =
-bt5-path =
-
-# modify this to reflect your local mysql configuration
-# Format:
-#     database[@host[:port]] [user [password [unix_socket]]]
-#   e.g "erp5db erp5user somepassword" or "erp5db erp5user"
-erp5_sql_connection_string = ${:mysql_database_name}@${:mysql_host}:${:mysql_port} ${:mysql_user} ${:mysql_password}
-
-zope_conf_template =
-  ${buildout:directory}/templates/default-erp5-standalone-zope.conf.in
-
-portal_id = erp5
-force-zodb-update = false
-# zope.conf template part BEGIN
-# instancehome and http-address have to be defined
-# User modifable keys:
-environment =
-  <environment>
-    PATH ${software_definition:software_home}/parts/imagemagick/bin:${software_definition:software_home}/parts/w3m/bin:${software_definition:software_home}/parts/xpdf/bin:${software_definition:software_home}/parts/ghostscript/bin:${software_definition:software_home}/parts/pdftk/bin:${software_definition:software_home}/parts/file/bin:${software_definition:software_home}/parts/graphviz/bin
-  </environment>
-debug-mode = off
-ip-address = 0.0.0.0
-# Good defaults, which do not have to be touched:
-clienthome = ${:instancehome}/var
-lib_path = ${:instancehome}/lib/python
-effective-user =
-enable-product-installation = on
-locale =
-datetime-format = us
-zserver-threads = 4
-python-check-interval = 500
-zserver-read-only-mode = off
-pid-filename = ${:clienthome}/Z2.pid
-lock-filename = ${:clienthome}/Z2.lock
-mime-types =
-structured-text-header-level = 3
-rest-input-encoding =
-rest-output-encoding =
-rest-header-level = 3
-rest-language-code = en
-cgi-environment =
-dns-server =
-http-realm = Zope
-cgi-maxlen = 0
-http-header-max-length = 8192
-automatically-quote-dtml-request-data = on
-trusted-proxy =
-publisher-profile-file =
-security-policy-implementation = C
-skip-authentication-checking = off
-skip-ownership-checking = on
-verbose-security = off
-maximum-number-of-session-objects = 1000
-session-add-notify-script-path =
-session-delete-notify-script-path =
-session-timeout-minutes = 20
-session-resolution-seconds = 20
-suppress-all-access-rules = off
-suppress-all-site-roots = off
-database-quota-size =
-read-only-database = off
-eventlog-level = info
-eventlog-path = ${:instancehome}/log/event.log
-access-level = WARN
-access-path = ${:instancehome}/log/Z2.log
-access-format = %(message)s
-warnfilter =
-max-listen-sockets = 100
-port-base = 0
-large-file-threshold =
-default-zpublisher-encoding = utf8
-http-force-connection-close = off
-zodb-path = ${:instancehome}/var/Data.fs
-# zope.conf template part ENDS
+environment-vars =
+  PATH ${software_definition:software_home}/parts/imagemagick/bin:${software_definition:software_home}/parts/w3m/bin:${software_definition:software_home}/parts/xpdf/bin:${software_definition:software_home}/parts/ghostscript/bin:${software_definition:software_home}/parts/pdftk/bin:${software_definition:software_home}/parts/file/bin:${software_definition:software_home}/parts/graphviz/bin
+zope-conf-additional =
+  # Timeserver to have ticks in zope
+  %import timerserver
+  <timer-server>
+    interval ${timer-server-interval}
+  </timer-server>
diff --git a/buildout/profiles/versions-2.12.cfg b/buildout/profiles/versions-2.12.cfg
index f502b69085..c155db6140 100644
--- a/buildout/profiles/versions-2.12.cfg
+++ b/buildout/profiles/versions-2.12.cfg
@@ -12,3 +12,6 @@ Products.DCWorkflow = 2.2.1nxd001
 
 # 1.0.3 fixes bug https://bugs.launchpad.net/zelenium/+bug/673610
 Products.Zelenium >= 1.0.3
+
+# erp5.recipe.zope2instance 1.x is for Zope-2.8
+erp5.recipe.zope2instance >= 2.0
diff --git a/buildout/profiles/versions-common.cfg b/buildout/profiles/versions-common.cfg
index bc988a13ce..4432171474 100644
--- a/buildout/profiles/versions-common.cfg
+++ b/buildout/profiles/versions-common.cfg
@@ -17,7 +17,6 @@ z3c.recipe.openoffice = 0.3.1dev2
 # requested
 erp5.recipe.mysqlserver >= 1.1.3
 erp5.recipe.sphinxserver >= 1.0.2
-erp5.recipe.standaloneinstance >= 0.4.4
 hexagonit.recipe.cmmi >= 1.3.1
 python-memcached >= 1.45
 xml-marshaller >= 0.9.2
diff --git a/buildout/profiles/versions.cfg b/buildout/profiles/versions.cfg
index 599fe69e8a..72540c9533 100644
--- a/buildout/profiles/versions.cfg
+++ b/buildout/profiles/versions.cfg
@@ -5,13 +5,17 @@ extends = ../profiles/versions-common.cfg
 [versions]
 # 0.20.8 is the latest version of itools that works with python-2.4.
 itools = 0.20.8
+
 # we sometimes have troubles with downloading alpha/beta version of
 # lxml, and this is the lates stable version.
 lxml = 2.2.8
+
 # official pysvn egg does not work with zc.recipe.egg, so we use our
 # modified version
 #pysvn = 1.7.2
+
 # zc.recipe.egg is pinned as this is known compatible versions with
 zc.recipe.egg = 1.2.2
-# plone.recipe.zope2instance 4.x is for Zope-2.12 or later
-plone.recipe.zope2instance = 3.6
+
+# erp5.recipe.zope2instance 2.x is for Zope-2.12 or later
+erp5.recipe.zope2instance = 1.3.1
diff --git a/buildout/software-profiles/erp5-2.12.cfg b/buildout/software-profiles/erp5-2.12.cfg
index 999f2b5989..a736de367d 100644
--- a/buildout/software-profiles/erp5-2.12.cfg
+++ b/buildout/software-profiles/erp5-2.12.cfg
@@ -149,8 +149,8 @@ eggs =
   erp5.recipe.mysqlserver
   erp5.recipe.ooodinstance
   erp5.recipe.sphinxserver
-  erp5.recipe.standaloneinstance
   erp5.recipe.testrunner
+  erp5.recipe.zope2instance
   plone.recipe.command
   plone.recipe.zeoserver
   plone.recipe.zope2instance
diff --git a/buildout/software-profiles/erp5.cfg b/buildout/software-profiles/erp5.cfg
index d73bcf064d..93f1c4e621 100644
--- a/buildout/software-profiles/erp5.cfg
+++ b/buildout/software-profiles/erp5.cfg
@@ -135,11 +135,10 @@ eggs =
   erp5.recipe.mysqlserver
   erp5.recipe.ooodinstance
   erp5.recipe.sphinxserver
-  erp5.recipe.standaloneinstance
   erp5.recipe.testrunner
+  erp5.recipe.zope2instance
   plone.recipe.command
   plone.recipe.zeoserver
-  plone.recipe.zope2instance
   supervisor
   z3c.recipe.mkdir
 
-- 
2.30.9