Re: [Zope-dev] INSTANCE_HOME and SOFTWARE_HOME still necessary in 2.7 start script?
Fred Drake wrote: On Friday 02 July 2004 02:21 am, Chris Withers wrote: > Well, the automatically generated runzope still includes INSTANCE_HOME and > SOFTWARE_HOME, hence my question... > > Can those variables be dropped from the template script? They were dropped, also back when I added App.config. I've looked back through the CVS history for both zopectl and runzope, and they've both been in them since day 1... in later. You should dig through the CVS log for clues as to why, asking the committer of that change if the log doesn't say why. Fred, why? ;-) You can also rip those variable out of the script and make sure everything still works. I'm going to give it a go. For what it's worth, I think they should go if at all possible. If 3rd party stuff is relying on them, it needs to be changed, I don't see why Zope should have confusing cruft (HOW many places do I need to set these variable?!) lying around... THAT said, thinking about it, you need to know where the .conf file is, and that's usually off the INSTANCE_HOME, and we need to know where run.py/zopectl.py are, and they're off the SOFTWARE_HOME. So these variables are kinda needed in the start script in one form or another. Which means, and I know how you feel about this, that to get them in one place, we'd need some way of telling ZConfig "get this value from the environment variable x". Is it really so bad if ZConfig grew a directive to that effect? I'd certainly not want anything magical to happen, but a way to explicitly say, in the .conf file, that this value is take from the environment, how about: %environment INSTANCE ...which would work just like a $define, except getting its value from the environment? cheers, Chris -- Simplistix - Content Management, Zope & Python Consulting - http://www.simplistix.co.uk ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] INSTANCE_HOME and SOFTWARE_HOME still necessary in 2.7 start script?
On Friday 02 July 2004 02:21 am, Chris Withers wrote: > Well, the automatically generated runzope still includes INSTANCE_HOME and > SOFTWARE_HOME, hence my question... > > Can those variables be dropped from the template script? They were dropped, also back when I added App.config. Someone added them back in later. You should dig through the CVS log for clues as to why, asking the committer of that change if the log doesn't say why. You can also rip those variable out of the script and make sure everything still works. -Fred -- Fred L. Drake, Jr. Zope Corporation ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] INSTANCE_HOME and SOFTWARE_HOME still necessary in 2.7 start script?
Fred Drake wrote: On Thursday 01 July 2004 07:42 pm, Chris Withers wrote: > Is it still necessary to specify INSTANCE_HOME and SOFTWARE_HOME in the > start script for Zope? I'm pretty sure I removed that requirement long ago, back when I added the App.config module. Cool :-) > Or would the following work? > python /my/path/to/Zope/startup/run.py -C /my/instance/path/zope.conf Try instead: /my/instance/path/bin/runzope Well, the automatically generated runzope still includes INSTANCE_HOME and SOFTWARE_HOME, hence my question... Can those variables be dropped from the template script? Chris -- Simplistix - Content Management, Zope & Python Consulting - http://www.simplistix.co.uk ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] INSTANCE_HOME and SOFTWARE_HOME still necessary in 2.7 start script?
On Thursday 01 July 2004 07:42 pm, Chris Withers wrote: > Is it still necessary to specify INSTANCE_HOME and SOFTWARE_HOME in the > start script for Zope? I'm pretty sure I removed that requirement long ago, back when I added the App.config module. > Or would the following work? > python /my/path/to/Zope/startup/run.py -C /my/instance/path/zope.conf Try instead: /my/instance/path/bin/runzope -Fred -- Fred L. Drake, Jr. Zope Corporation ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] INSTANCE_HOME and SOFTWARE_HOME still necessary in 2.7 start script?
Hi there, Is it still necessary to specify INSTANCE_HOME and SOFTWARE_HOME in the start script for Zope? Or would the following work? python /my/path/to/Zope/startup/run.py -C /my/instance/path/zope.conf cheers, Chris -- Simplistix - Content Management, Zope & Python Consulting - http://www.simplistix.co.uk ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] INSTANCE_HOME and Win32
Thanks... seem's to work. -- Andy McKay. - Original Message - From: "Chris Withers" <[EMAIL PROTECTED]> To: "Andy McKay" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Sunday, April 01, 2001 4:20 PM Subject: Re: [Zope-dev] INSTANCE_HOME and Win32 > Andy McKay wrote: > > > > In 4am's how to on using INSTANCE HOME he says "copy start and stop to the > > site directory". Whats start and stop? > > start.bat is the closest on Win32. > > Anyway, the short version is, create a folder 'current', copy the var and > extensions folders of your favourite Zope setup into it, then copy any products > you want specific version of into current/Products. > > Then change start.bat so it looks a bit like: > "E:\Zope\2.3.1\bin\python.exe" "E:\Zope\2.3.1\z2.py" > INSTANCE_HOME="E:\Zope\current" > > ...that'll start up a Zope instance on port 8080, using the version of Zope in > E:\Zope\2.3.1 but the data.fs and other bits from E:\Zope\current\var > > good luck, > > Chris > > ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] INSTANCE_HOME and Win32
Andy McKay wrote: > > In 4am's how to on using INSTANCE HOME he says "copy start and stop to the > site directory". Whats start and stop? start.bat is the closest on Win32. Anyway, the short version is, create a folder 'current', copy the var and extensions folders of your favourite Zope setup into it, then copy any products you want specific version of into current/Products. Then change start.bat so it looks a bit like: "E:\Zope\2.3.1\bin\python.exe" "E:\Zope\2.3.1\z2.py" INSTANCE_HOME="E:\Zope\current" ...that'll start up a Zope instance on port 8080, using the version of Zope in E:\Zope\2.3.1 but the data.fs and other bits from E:\Zope\current\var good luck, Chris ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] INSTANCE_HOME and Win32
In 4am's how to on using INSTANCE HOME he says "copy start and stop to the site directory". Whats start and stop? My second Zope instance is wanting to lock the same file on start up... E:\Zope\lib\python\ZODB\lock_file.py line 115 in lock_file -- Andy McKay. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] INSTANCE_HOME vs. SOFTWARE_HOME
On Sun, Mar 18, 2001 at 10:18:52PM +0100, Morten W. Petersen wrote: > Hi guys, > > some people have asked me to use INSTANCE_HOME instead of SOFTWARE_HOME, > which breaks their products on debian distros. > > Now, I'm not sure that won't break other systems if I change it; anyone > care to share? What are you using the variable for? If you want to reach the var, import or Extensions directories, use INSTANCE_HOME, if you want to reach a Products directory, use both variables. On Debian systems, Zope is by default installed as a seperate INSTANCE_HOME and SOFTWARE_HOME system. -- Martijn Pieters | Software Engineer mailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ - ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] INSTANCE_HOME vs. SOFTWARE_HOME
Hi guys, some people have asked me to use INSTANCE_HOME instead of SOFTWARE_HOME, which breaks their products on debian distros. Now, I'm not sure that won't break other systems if I change it; anyone care to share? Thanks, Morten ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] INSTANCE_HOME breaks cross products import
Hi, I'm using then the INSTANCE_HOME to have separate Zope instances use a base zope installation and a shared products directory with symlink's to the instance product folder. As described in the "How-To: Make your life easier with INSTANCE_HOME" by 4am. Now the LoginManager can't import anything from the ZPattern module. 2000-10-17T21:59:14 ERROR(200) Zope Couldn't import Products.LoginManager Traceback (innermost last): File /bigshare/zopeservers/Zope-2.2.2-base/lib/python/OFS/Application.py, line 397, in import_products (Object: string) File /bigshare/zopeservers/unitedrings/Products/LoginManager/__init__.py, line 1, in ? File /bigshare/zopeservers/unitedrings/Products/LoginManager/LoginManager.py, line 9, in ? ImportError: cannot import name SheetProviderContainer Now this works fine if I start Zope from the base Zope installation. So what goes wrong and why? Does I do anything wrong or should/could this be fixed in the product? If so I guess it would be practical to document som product author guidelines. Regards, Johan Carlsson ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] INSTANCE_HOME, SOFTWARE_HOME and package_home
Evan Simpson wrote: > > f=open('%s/Products/%s.dtml' % (SOFTWARE_HOME,file)) > > E:\Zope\2.2.0\lib\python/Products/Squishdot/validArticle.dtml > >f=open('%s/Products/%s.dtml' % (INSTANCE_HOME,file)) > > 'E:\\Zope\\2.2.0/Products/Squishdot/validArticle.dtml' > > This looks correct to me. Not to me! :-( Okay, I can understand (but not approve of) having a mixture of \ and / in a string (I guess python's open takes care of that) but what's with the \\ in the INSTANCE_HOME case?! Also be my comment on the /lib/python bit below ;-) > If no explicit INSTANCE_HOME is set, it defaults > to SOFTWARE_HOME minus '/lib/python'. Can you explain why that makes sense please ;-) Surely it'd be more useful to default to SOFTWARE_HOME including '/lib/python' so that old code wasn't broken? > On the other hand, I wonder why you're constructing '%s/Products/' paths > explicitly like this. It was done by Butch ages ago. He probably did it 'cos it worked and the 'correct' way wasn't documented anywhere :P > If this code is inside the Product to which you would > like the path, the proper way to get the path is: > > from Globals import package_home > path = package_home(globals()) > # path now probably equals > 'E:\\Zope\\2.2.0\\lib\\python\\Products\\Squishdot' in your example. And that'll work in INSTANCE_HOME (in either the base or instance parts) Zope installs as well as non-instance home ones? > I have no idea if or where this is documented, sadly. no comment ;-) > I'll definitely put > it in my 'writing INSTANCE_HOME-friendly Products' howto, as soon as I get > around to writing such a thing :-/ Soon, I hope, 'cos it sounds like a great idea > Or perhaps you could? ;-) The biggest thing I think is needed is a clear definition of what all of these _should_ be and what they _are_. This needs to be done by someone who understands them all and that's clearly not me ;-) cheers, Chris ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] INSTANCE_HOME
does anybody know where REQUEST['INSTANCE_HOME'] disappeared to between Zope version 2.1.4 and version 2.1.6. Furthermore is it likely to reappear or has it been succeeded by some other key. Cheers, -Andy Dawkins ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )