[Zope-Checkins] CVS: Zope/lib/python/Zope/Startup - run.py:1.1.2.6

Andreas Jung andreas at andreas-jung.com
Sun May 16 11:09:57 EDT 2004


Update of /cvs-repository/Zope/lib/python/Zope/Startup
In directory cvs.zope.org:/tmp/cvs-serv15026

Modified Files:
      Tag: Zope-2_7-branch
	run.py 
Log Message:
reverting ZOPE_CONFIG patch. going back to 1.1.2.3


=== Zope/lib/python/Zope/Startup/run.py 1.1.2.5 => 1.1.2.6 ===
--- Zope/lib/python/Zope/Startup/run.py:1.1.2.5	Sat May 15 03:54:25 2004
+++ Zope/lib/python/Zope/Startup/run.py	Sun May 16 11:09:54 2004
@@ -14,22 +14,18 @@
 
 def run():
     """ Start a Zope instance """
-    import Zope.Startup
-    starter = Zope.Startup.get_starter()
+    from Zope.Startup import start_zope
     opts = _setconfig()
-    starter.setConfiguration(opts.configroot)
-    starter.prepare()
-    starter.run()
+    start_zope(opts.configroot)
 
 def configure(configfile):
     """ Provide an API which allows scripts like zopectl to configure
     Zope before attempting to do 'app = Zope.app(). Should be used as
     follows:  from Zope.Startup.run import configure;
     configure('/path/to/configfile'); import Zope; app = Zope.app() """
-    import Zope.Startup
-    starter = Zope.Startup.get_starter()
+    from Zope.Startup import ZopeStarter
     opts = _setconfig(configfile)
-    starter.setConfiguration(opts.configroot)
+    starter = ZopeStarter(opts.configroot)
     starter.setupSecurityOptions()
     starter.dropPrivileges()
 
@@ -41,11 +37,11 @@
     from App import config
     opts = options.ZopeOptions()
     if configfile:
-        opts.configfile = configfile
+        opts.configfile=configfile
         opts.realize(doc="Sorry, no option docs yet.", raise_getopt_errs=0)
     else:
         opts.realize(doc="Sorry, no option docs yet.")
-
+        
     handlers.handleConfig(opts.configroot, opts.confighandlers)
     import App.config
     App.config.setConfiguration(opts.configroot)




More information about the Zope-Checkins mailing list