[Checkins] SVN: zam.demo/trunk/ Initial import of the buildout. No need to make this a package.

Stephan Richter srichter at cosmos.phy.tufts.edu
Thu Mar 13 06:54:58 EDT 2008


Log message for revision 84634:
  Initial import of the buildout. No need to make this a package.
  

Changed:
  A   zam.demo/trunk/
  A   zam.demo/trunk/CHANGES.txt
  A   zam.demo/trunk/README.txt
  A   zam.demo/trunk/bootstrap.py
  A   zam.demo/trunk/buildout.cfg
  A   zam.demo/trunk/externals/

-=-
Added: zam.demo/trunk/CHANGES.txt
===================================================================
--- zam.demo/trunk/CHANGES.txt	                        (rev 0)
+++ zam.demo/trunk/CHANGES.txt	2008-03-13 10:54:57 UTC (rev 84634)
@@ -0,0 +1,8 @@
+=======
+CHANGES
+=======
+
+Version 0.1.0 (unreleased)
+-------------------------
+
+- Initial Release


Property changes on: zam.demo/trunk/CHANGES.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zam.demo/trunk/README.txt
===================================================================
--- zam.demo/trunk/README.txt	                        (rev 0)
+++ zam.demo/trunk/README.txt	2008-03-13 10:54:57 UTC (rev 84634)
@@ -0,0 +1,10 @@
+This is a simple buildout to demonstrate all features available to ZAM, once
+all plugins are installed.
+
+To get started:
+
+  $ python bootstrap.py
+  $ ./bin/buildout -N
+  $ ./bin/app
+
+Enjoy!


Property changes on: zam.demo/trunk/README.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zam.demo/trunk/bootstrap.py
===================================================================
--- zam.demo/trunk/bootstrap.py	                        (rev 0)
+++ zam.demo/trunk/bootstrap.py	2008-03-13 10:54:57 UTC (rev 84634)
@@ -0,0 +1,52 @@
+##############################################################################
+#
+# Copyright (c) 2007 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+"""Bootstrap a buildout-based project
+
+Simply run this script in a directory containing a buildout.cfg.
+The script accepts buildout command-line options, so you can
+use the -c option to specify an alternate configuration file.
+
+$Id$
+"""
+
+import os, shutil, sys, tempfile, urllib2
+
+tmpeggs = tempfile.mkdtemp()
+
+ez = {}
+exec urllib2.urlopen('http://peak.telecommunity.com/dist/ez_setup.py'
+                     ).read() in ez
+ez['use_setuptools'](to_dir=tmpeggs, download_delay=0)
+
+import pkg_resources
+
+cmd = 'from setuptools.command.easy_install import main; main()'
+if sys.platform == 'win32':
+    cmd = '"%s"' % cmd # work around spawn lamosity on windows
+
+ws = pkg_resources.working_set
+assert os.spawnle(
+    os.P_WAIT, sys.executable, sys.executable,
+    '-c', cmd, '-mqNxd', tmpeggs, 'zc.buildout',
+    dict(os.environ,
+         PYTHONPATH=
+         ws.find(pkg_resources.Requirement.parse('setuptools')).location
+         ),
+    ) == 0
+
+ws.add_entry(tmpeggs)
+ws.require('zc.buildout')
+import zc.buildout.buildout
+zc.buildout.buildout.main(sys.argv[1:] + ['bootstrap'])
+shutil.rmtree(tmpeggs)


Property changes on: zam.demo/trunk/bootstrap.py
___________________________________________________________________
Name: svn:keywords
   + Id

Added: zam.demo/trunk/buildout.cfg
===================================================================
--- zam.demo/trunk/buildout.cfg	                        (rev 0)
+++ zam.demo/trunk/buildout.cfg	2008-03-13 10:54:57 UTC (rev 84634)
@@ -0,0 +1,145 @@
+[buildout]
+develop = externals/z3c.menu.ready2go
+          externals/zam.api
+          externals/zam.skin
+	  externals/zamplugin.control
+	  externals/zamplugin.error
+	  externals/zamplugin.navigation
+	  externals/zamplugin.sampledata
+	  externals/zamplugin.sitemanager
+	  externals/z3c.contents
+	  externals/z3c.jsontree
+          externals/z3c.jsonrpcproxy
+          externals/z3c.table
+          externals/z3c.xmlhttp
+parts = var app
+
+[app]
+recipe = z3c.recipe.dev:app
+eggs = zam.skin
+       zam.api
+       zamplugin.control
+       zamplugin.error
+       zamplugin.navigation
+       zamplugin.sampledata
+       zamplugin.sitemanager
+       z3c.xmlhttp
+       z3c.jsonrpcproxy
+server = zserver
+zope.conf =
+  ${var:zconfig}
+
+  <server>
+    type WSGI-HTTP
+    address 8080
+  </server>
+
+  <eventlog>
+    <logfile>
+      formatter zope.exceptions.log.Formatter
+      path ${buildout:directory}/parts/error.log
+    </logfile>
+    <logfile>
+      formatter zope.exceptions.log.Formatter
+      path STDOUT
+    </logfile>
+  </eventlog>
+
+  <accesslog>
+    <logfile>
+      path ${buildout:directory}/parts/access.log
+    </logfile>
+    <logfile>
+      path STDOUT
+    </logfile>
+  </accesslog>
+
+site.zcml =
+  <configure
+      xmlns:meta="http://namespaces.zope.org/meta"
+      xmlns:browser="http://namespaces.zope.org/browser"
+      i18n_domain="zope">
+
+  <!-- use app configuration from zam.api -->
+  <include package="zam.skin" file="app.zcml" />
+
+  <!-- include z3c meta configuration -->
+  <include package="z3c.jsonrpc" file="meta.zcml" />
+
+  <!-- include z3c configuration -->
+  <include package="z3c.json" />
+  <include package="z3c.jsonrpc" />
+  <include package="z3c.jsontree" />
+
+  <!-- zam skin configuration -->
+  <include package="zamplugin.control" />
+  <include package="zamplugin.error" />
+  <include package="zamplugin.navigation" />
+  <include package="zamplugin.sampledata" />
+  <include package="zamplugin.sitemanager" />
+
+  <!-- load other zcml files -->
+  <include file="securitypolicy.zcml" />
+  <include file="principals.zcml" />
+
+  </configure>
+
+principals.zcml =
+  <unauthenticatedPrincipal
+      id="lovelybooks.anybody"
+      title="Unauthenticated User"
+      />
+
+  <unauthenticatedGroup
+      id="zope.Anybody"
+      title="Unauthenticated Users"
+      />
+
+  <authenticatedGroup
+      id="zope.Authenticated"
+      title="Authenticated Users"
+      />
+
+  <everybodyGroup
+      id="zope.Everybody"
+      title="All Users"
+      />
+
+  <principal
+      id="zope.manager"
+      title="Manager"
+      login="Manager"
+      password="password"
+      />
+
+  <grant
+      role="zope.Manager"
+      principal="zope.manager"
+      />
+
+securitypolicy.zcml =
+  <include package="zope.app.securitypolicy" />
+
+  <securityPolicy
+      component="zope.securitypolicy.zopepolicy.ZopeSecurityPolicy" />
+
+  <role id="zope.Anonymous" title="Everybody"
+                 description="All users have this role implicitly" />
+  <role id="zope.Manager" title="Site Manager" />
+  <role id="zope.Member" title="Site Member" />
+
+  <!-- Replace the following directive if you don't want public access -->
+  <grant
+      permission="zope.View"
+      role="zope.Anonymous"
+      />
+  <grant
+      permission="zope.app.dublincore.view"
+      role="zope.Anonymous"
+      />
+
+  <grantAll role="zope.Manager" />
+
+
+[var]
+recipe = zc.recipe.filestorage



More information about the Checkins mailing list