Hi Chris,

Chris McDonough wrote at 2003-3-11 18:39 -0500:
 > On Tue, 2003-03-11 at 17:11, Dieter Maurer wrote:
 > >   All this is achieved by incorporating the result of "hostname"
 > >   into the respective environment variables.
 > >   
 > >   I do not know how to do something like this in a configuration
 > >   file (unless it provides for some form of shell functionality).
 > 
 > ZConfig does allow you to declare and use simple bash-style variables
 > within a single file,

When the configuration is composed out of components (e.g. for
packages), then some global declarations might be very
useful. I.e. a features as the global parameters in XSLT.
This would allow to have a single place to change all dependent
components (locations are most likely candidates for this feature).

 > but currently provides no access to the
 > environment.  I suspect we could add something to obtain an envvar value
 > within ZConfig.
 > 
 > E.g.:
 > 
 > %define HOSTNAME ${HOSTNAME}
 > 
 > .. then refer to $HOSTNAME in the rest of the config file...
 > 
 > (squiggly brackets would mean obtain from environment).
 > 
 > Do you think this would suffice?

For us, it would.

But the syntax could be a bit more explicit,
maybe ${env HOSTNAME} (a la "make", where the first word
in "${...}" may be a function).

 > Or maybe we just make HOSTNAME and/or
 > IP_ADRRESS within the a "key constant" as you describe.

I like access to the environment more.

 > >  > - Building and installing the software have become more clearly
 > >  >   distinct; the installation can be separate from the build.
 > > 
 > > Seems you make the elementary installation more difficult.
 > 
 > I'm surprised at this assertion.  The most elementary way of install
 > under 2.7 is this:
 > 
 > $ cd Zope-src
 > $ ./configure 
 > {finds suitable Python and reports lack of large file support}
 > $ make
 > $ make install
 > $ /opt/zope/mkzopeinstance /tmp/inst
 > {user edits /tmp/inst/etc/zope.conf, which has inline docs}
 > $ /tmp/inst/zopectl start
 > 
 > While under 2.6 it's this:
 > 
 > {need to know to configure Python with largefile support}
 > $ cd Zope-src
 > $ /path/to/python/version/you/want wo_pcgi.py 
 > {user finds and reads doc/ENVIRONMENT.txt for envvars}
 > {user finds and reads z2.py for command-line switches}
 > {user edits the 'start' script with the right switches and envvars}
 > $ ./start

I never read "ENVIRONMENT.txt"; for elementary use, I need
neither read "z2.py" nor do anything with "start".

These things may come later, when newbies are already a bit
acquainted with Zope.


Dieter

_______________________________________________
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 )

Reply via email to