Commit bbccc614 authored by Amos Latteier's avatar Amos Latteier

doc reorg

parent 97a39137
Building and installing Zope
Building and installing Zope from source
----------------------------------------
This document describes building and installing Zope on Unix.
We will provide Windows instructions in later releases. We
will also provide binary releases for some platforms.
Building Zope:
Building Zope
There are some python scripts in the top-level directory that should
help you get started. You must run these scripts from the top-level
directory.
If you want to try out Zope in the simplest fashion using a
Python web server, then run the script wo_pcgi:
Python web server, then run the script wo_pcgi::
python wo_pcgi.py
If you want to use PCGI and an existing web server, run w_pcgi:
If you want to use PCGI and an existing web server, run w_pcgi::
python w_pcgi.py
Notes:
Notes
* You should be using Python 1.5.1 to run the build scripts.
* To build python extensions you need to have Python configuration
......@@ -29,33 +30,54 @@ Building Zope:
* If you just want to use Zope components it's not necessary to build Zope
but it's a good idea since it will compile Python C extensions for you.
Setting the Zope super user name and password:
The Zope super user has full access to Zope online management
facilities. The super user account is defined by a file named
'access' in the Zope directory. This file should contain one
line, which is the super user name followed by a colon followed by
the password. For example:
Setting the Zope "super manager" name and password
mario:nintendoRulez
Because Zope is managed through the web, user names and passwords must be
used to assure that only authorized people can make changes to a Zope
installation. User names and passwords are normally defined by creating
and modifying user folders within Zope.
A special "super manager" user name and password are defined outside
the application for two reasons:
- Some user name and password are needed to enable creation of
initial normal managers of your Zope site.
- The "super manager" provides an all-powerful user that can do
anything in the application and whose password cannot be changed
through the application user interface.
This user name and password is defined in the 'access' file located
in the Zope directory. It should be readable only by the user
as which your web server runs.
The super manager username and password should only be used when
defining the normal management users and passwords and when dealing
with unusual situations, like lost (or hacked) manager user names and
passwords.
The access file should consist of a single line of the form:
name:password
The build scripts automatically create an 'access' file for you,
using a default username and password of:
superuser:123
It is *highly recommended* that you change the default superuser
It is *highly recommended* that you change the default super manager
name and password by editing your 'access' file after running the
build script. When you begin managing your Zope installation you
will need to enter the superuser name and password when prompted.
Note that you may also add an optional third component to the line
in the access file to restrict superuser access by domain.
in the access file to restrict super manager access by domain.
For example, the line:
mario:nintendoRules:*.mydomain.com
in your 'access' file will only allow superuser access to your
in your 'access' file will only allow super manager access to your
installation from *.mydomain.com machines. Attempts to access the
system from other domains will fail, even if the correct superuser
name and password are used.
......@@ -63,71 +85,55 @@ Setting the Zope super user name and password:
Setting permissions ons on the var directory.
You need to set permissions on the Zope var directory.
Zope needs to read and write data from its var directory. Before
running Zope you should insure that you give adequate permissions
to the Zope var directory. For example to give full read/write
permissions to the Zope var directory cd to the Zope directory and
then type:
running Zope you should ensure that you give adequate permissions
to the Zope var directory for the userid Zope will run under.
chmod 0777 var
Depending on how you choose to run Zope you will need to give different
permissions to the var directory. For example if you are using
ZopeHTTPServer which normally runs as your userid, you need only ensure
that your userid has read and write permissions to the var directory.
If you use Zope with an existing web server, it will probably run Zope
as 'nobody'. In this case 'nobody' needs read and write permissions to
the var directory.
Note: Zope normally runs as nobody, so full read and write permissions
on the var directory is normally needed.
If you change the way you run Zope you may need to modify the permissions
of the var directory and the files in it to allow Zope to read and write
under its changed userid.
Using Zope with ZopeHTTPServer:
Using Zope with ZopeHTTPServer
ZopeHTTPServer is a simple web server written in Python and it
allows you to run Zope without using PCGI and another web server.
The build script automatically creates a shell script named serve.sh
which will run the built-in server. To start Zope using ZopeHTTPServer
cd to the Zope directory and issue the command:
cd to the Zope directory and issue the command::
serve.sh
Using Zope with PCGI:
Starting Zope with an existing web server
PCGI is the traditional way of running Zope. PCGI mediates
between your existing web server and Zope. To use PCGI copy the
Zope.cgi file to your web server's cgi-bin directory. You can also
create a symbolic link to Zope.cgi from your cgi-bin directory.
For example:
See the WEBSERVERS.txt file for more information about configuring Zope
with an existing web server.
ln -s /home/amos/Zope/Zope.cgi /usr/local/apache/cgi-bin/Zope
At this point you should perform any other steps you web server
requires to install and configure a cgi script.
Accessing Zope through the web
Note: For more information on PCGI checkout Jeff Bauer's PCGI pages:
After you either start ZopeHTTPServer or set up Zope with your web server
you should be able to start using Zope through the web. Point your browser
to either:
http://starship.skyport.net/crew/jbauer/persistcgi/
If you are using Apache you will need to trick Apache into passing
authentication headers to Zope. The easiest way to do this is to
use mod_rewrite. Here is an example of configuration information
which you would place in an Apache conf file:
# Zope configuration maps /Zope/ to the Zope.cgi PCGI script
RewriteEngine on
RewriteCond %{HTTP:Authorization} ^(.*)
RewriteRule ^/Zope/(.*) /usr/local/apache/cgi-bin/Zope.cgi/$1 [e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l]
Note that the RewriteRule should be one long line.
Accessing Zope:
After you either start ZopeHTTPServer or set up PCGI you should be
able to start using Zope through the web. Point your browser to either:
http://localhost:8080/manage
'http://localhost:8080/manage'
if you are using ZopeHTTPServer or whatever the relevant URL is, if
you are using PCGI. If you're using PCGI make sure to tack '/manage'
on after the name of the Zope CGI script so that you go to the
management screen. For example the URL may be something like:
http://localhost/cgi-bin/Zope.cgi/manage
'http://localhost/cgi-bin/Zope.cgi/manage'
You will be prompted to enter a user name and a password. Enter the
super user name and password you specified in the access file.
......@@ -138,9 +144,10 @@ Accessing Zope:
different management functions with the tabs at the top of the frame.
If you haven't used Zope before, you should head to the Zope web site
and read some documentation.i The Zope Manager's Guide is a good place
to start.
and read some documentation. The Zope Manager's Guide is a good place
to start. You can access the Zope site at:
http://www.zope.org
'http://www.zope.org/'
Have fun!
Zope Public License (ZPL) Version 0.9.4
---------------------------------------
Copyright (c) Digital Creations. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
1. Redistributions in source code must retain the above copyright
notice, this list of conditions, and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions, and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
3. Any use, including use of the Zope software to operate a website,
must either comply with the terms described below under
"Attribution" or alternatively secure a separate license from
Digital Creations.
4. All advertising materials, documentation, or technical papers
mentioning features derived from or use of this software must
display the following acknowledgement:
"This product includes software developed by Digital Creations
for use in the Z Object Publishing Environment
(http://www.zope.org/)."
5. Names associated with Zope or Digital Creations must not be used to
endorse or promote products derived from this software without
prior written permission from Digital Creations.
6. Redistributions of any form whatsoever must retain the following
acknowledgment:
"This product includes software developed by Digital Creations
for use in the Z Object Publishing Environment
(http://www.zope.org/)."
7. Modifications are encouraged but must be packaged separately as
patches to official Zope releases. Distributions that do not
clearly separate the patches from the original work must be clearly
labeled as unofficial distributions.
Disclaimer
THIS SOFTWARE IS PROVIDED BY DIGITAL CREATIONS ``AS IS'' AND ANY
EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL DIGITAL CREATIONS OR ITS
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
Attribution
Individuals or organizations using this software as a web site must
provide attribution by placing the accompanying "button" and a link
to the accompanying "credits page" on the website's main entry
point. In cases where this placement of attribution is not
feasible, a separate arrangment must be concluded with Digital
Creations. Those using the software for purposes other than web
sites must provide a corresponding attribution in locations that
include a copyright using a manner best suited to the application
environment.
This software consists of contributions made by Digital Creations and
many individuals on behalf of Digital Creations. Specific
attributions are listed in the accompanying credits file.
Welcome to Zope beta 1 source release.
This document provides some general information about the Zope
source release and provides links to other documents.
Installation information can be found in doc/INSTALL.txt.
Zope information is available at http://www.zope.org
Report problems with this release on the Zope mailing list
(zope@zope.org) To subscribe to the list send mail to
zope-request@zope.org with "subscribe" in the subject line.
Introduction:
The source release is intended for tinkerers, those who want
to use Zope components separately, Bobo hackers, and people
who aren't afraid of programming.
If you just want to use Zope easily and aren't a programmer
the binary release will probably suit you better.
License
A preliminary version of the Zope License is included in docs/LICENSE.txt
We are still working on finalizing the license. Send your feeback about
the license to paul@digicool.com
Installing Zope:
Follow the instructions in INSTALL.txt to install Zope. You
may wish to run the installer even if you only plan on using
selected Zope components since the install script compiles
Python extensions for you that you may want, like cDocumentTemplate.
Using Zope Components Separately
Zope consists of many Python packages which can be profitably
used by themselves. For example you will find all your old friends
from Bobo here:
* ZPublisher - A packagized version of the Bobo ORB you know and
love. It's been updated with new thinks like support for
__bobo_debug_mode__ More info to come soon.
* DocumentTemplate - This package includes cDocumentTemplate which
speeds things up considerably.
* BoboPOS - This is NOT BoboPOS3. It a version of BoboPOS2 which
include c code to make things faster.
You can find most of these packages in the lib/python directory. If
you poke around, you might find other goodies too, like StructuredText.
We plan on making separate releases of these packages soon.
Notes:
* Zope requires Python 1.5.1
* Lots more documentation is coming.
* Don't forget to check the Zope web site and mailing list.
* Read the source, have fun!
Using Zope with an existing web server
--------------------------------------
While Zope comes with a web server, you may wish to use it with an
existing web server. Use Persistent CGI (PCGI) to allow your existing
web server to work with Zope on Unix and Windows.
The installation process should create a 'Zope.cgi' PCGI file. Copy the
'Zope.cgi' file to your web server's cgi-bin directory.
On Unix you can also create a symbolic link to 'Zope.cgi' from your cgi-bin
directory. For example::
ln -s /home/amos/Zope/Zope.cgi /usr/local/apache/cgi-bin/Zope
At this point you should perform any other steps you web server
requires to install and configure a CGI script.
Note: For more information on PCGI check out Jeff Bauer's PCGI pages:
http://starship.skyport.net/crew/jbauer/persistcgi/
When your Zope.cgi file is correctly configured as a CGI script with
your web server, you are ready to access Zope through the web. You should
point your browser at:
'http://youmachine.example.com:8998/cgi-bin/Zope.cgi/manage'
(Your URL maybe be different depending on how your web server is configured.)
You should be prompted to enter a username and password. Enter the Zope
"super manager" name and password.
Zope authentication with existing web servers.
Zope normally performs both authentication and authorization of users.
Some web servers don't pass authentication information to CGI scripts.
Tricking Apache to pass authentication headers
If you are using Apache you will need to trick Apache into passing
authentication headers to Zope. The easiest way to do this with
Apache 1.3 and above is to use mod_rewrite. Here is an example of
configuration information which you would place in an Apache conf file::
# Zope configuration maps /Zope/ to the Zope.cgi CGI script
RewriteEngine on
RewriteCond %{HTTP:Authorization} ^(.*)
RewriteRule ^/Zope/(.*) /usr/local/apache/cgi-bin/Zope.cgi/$1 [e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l]
Note that the RewriteRule should be one long line, and that the last
character is the letter l, not the number 1.
Allowing your server to handle authentication itself
As of 1.0.9, Zope began supporting a mode that allowed the web
server to handle authentication. The 'REMOTE_USER' environment
variable is then matched to the identity of a user object in
Zope.
The following provide step-by-step instructions for setting this up in
Apache, allowing both the Zope "super manager" defined in the Zope
'access' file and users defined in Zope User Folders to be authenticated
via the web server.
Get Apache to authenticate /cgi-bin/Zope
Add a directive in your Apache configuration file such as::
<Location /cgi-bin/Zope/>
AuthType Basic
AuthName Zope-realm
AuthUserFile /usr/local/etc/httpd/conf/ru_users
require valid-user
</Location>
Then send Apache a '-1' signal to tell it to re-read its
configuration files. *Note*: the above presumes that
'/cgi-bin/Zope' has been made executable by some other Apache
directive in the configuration file.
Ensure Apache Has 'superuser'
Using Apache's tools for managing a user database, make
sure that the 'AuthUserFile' defined above has a valid user
called 'superuser'.
Get Zope to use Apache's authentication
Change Zope's access file to contain just the superuser
id followed by a colon, as in::
superuser:
Note that this can be any value, including spaces. The only
restriction is that the value must match a user defined in
Apache's user database.
Shut down Zope by doing::
kill `cat var/Main.pid`
from the Zope directory.
Configure Zope
At this point you are able to log in using the "superuser"
identity. If you want other people defined in the Apache user
database to have identities in Zope, you need to add them to
a User Folder (the object whose ID is acl_users). Either click on
the pre-defined acl_users in the top folder or add a User Folder
object to a subfolder.
Specific web servers
Apache
* As mentioned above, Apache does not pass authorization information
to CGI scripts by default. See above for information on how to deal
with this situation.
Netscape Servers
* Like Apache, Netscape does not pass HTTP Authorization information to
CGI scripts. We have a plugin at our website that addresses this.
http://www.digicool.com
* Alternatively, you can allow the web server to perform the
authentication step. See above for more information.
IIS
* You must turn off Windows NT Challenge/Response authentication.
To do this, go to IIS Manager, right-click on the server, select
Service Properties, and deselect *both* 'Windows NT
Challenge/Response' and, strangely, Basic Authentication from the
Password Authentication area of the Service tabbed worksheet.
* IIS kindly throws out PATH_INFO when writing to its logs, so if
you want to log which Zope objects are actually being
accessed, you will need to investigate an ISAPI filter
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment