alcatraz-core.zipdigilib-tomconf.zip (Not essential)digilib-win-conf.zip (Not essential)/docuserver) and for the web interface
(/docuserver/www).alcatraz-core package in the web
interface directory (/docuserver/www). This will create
the digilib directory digitallibrary./docuserver This should
produce a directory /docuserver/jakarta-tomcat-4.1.24. Create a
link /docuserver/tomcat to the new directory.digilib-tomconf in the tomcat directory./docuserver/tomcat/webapps (type ln -s
/docuserver/www/digitallibrary /docuserver/tomcat/webapps) This is
the default installation running on port 8080 as
http://myserver:8080/digitallibrary/.catalina.sh (in the directory
/docuserver/tomcat/bin, see below for details)tomcat/bin/rctomcat
to start and stop the tomcat server. Copy the script into
/etc/init.d as tomcat and set runlevel
links accordingly.wwwrun (or whatever your webserver runs) and
use this account to start the tomcat server.http://myserver:8080/docuserver/digitallibrary/xul/install.html
in a Mozilla compatible browser. There the users can find
instructions to install XUL-Components into their browser. Set the following Environment Variables:
CATALINA_HOME = C:\jakarta-tomcat-4.1.24 (or similar)
JAVA_HOME = C:\j2sdk (or similar)
Start Tomcat server: Open a console window (start cmd.exe).
Type: %CATALINA_HOME%\bin\startup
Try the following URL in your browser:
http://localhost:8080 or
http://127.0.0.1:8080
You should now be able to see the Tomcat opening screen: If you're seeing this page via a web browser, it means you've setup Tomcat successfully. Congratulations!
Shut it down again: In the console window type %CATALINA_HOME%\bin\shutdown.
Extract the "Alcatraz" distribution, possibly to C:\docuserver. Modify the following configuration files according to your paths (as in the "On Linux" section):
For tomcat
C:\jakarta-tomcat-4.1.24\conf\server.xmlC:\jakarta-tomcat-4.1.24\conf\tomcat-users.xmlFor digilib
C:\docuserver\digitallibrary\WEB-INF\web.xmlC:\docuserver\digitallibrary\WEB-INF\digilib-config.xmlC:\docuserver\digitallibrary\WEB-INF\digilib-auth.xmlIn the alcatraz-win-conf.zip package you can find
prepared configuration files with the following default values:
C:\bilder. digilib.digilib.9090.
Now you can restart the Tomcat server: http://localhost:9090 or
http://127.0.0.1:9090.
Watch the images:
http://localhost:9090/docuserver/digitallibrary/digilib.jsp?&lv=2
The file catalina.sh (in /docuserver/tomcat/bin
can be modified to provide the path to the JDK and runtime options
for the Java VM. Somewhere at the beginning of the file you can put two lines
like this:
export JAVA_HOME=/usr/local/lib/IBMJava2-14 export CATALINA_OPTS="-mx512m"
or, on Windows
set CATALINA_HOME=C:\jakarta-tomcat-4.1.24 set JAVA_HOME=C:\j2sdk
Adjust the JAVA_HOME path to point to your Java JDK
installation directory. You can adjust the memory used by the Java VM
with the -mx option.
You can delete those two lines if you set these variables in your shell before starting tomcat in that same shell. These lines are needed if you want to use the startup script mentioned above under linux .
All passwords and usernames have to be set up in the file
tomcat-users.xml in /docuserver/tomcat/conf if you
want to use authentication in digilib. The file looks like this:
<tomcat-users> <user name="tomcat" password="tomcat" roles="tomcat" /> <user name="role1" password="tomcat" roles="role1" /> <user name="both" password="tomcat" roles="tomcat,role1" /> </tomcat-users>
A user is identified by a name and
password. These two elements have to be entered in a
authentication form presented by the browser when accessing a
restricted resource. A user can have one or more
roles. These roles will be used by digilib to decide if
an authenticated user is allowed to access a document (see
digilib-auth.xml below).
If you want to use the webinterface to configure Tomcat, you have to
add administrational account with the roles admin and
manager.
tomcat has to be restarted before changes to
tomcat-users.xml have effect!
The deployment of the digilib servlets and JSPs is defined in the
file web.xml in the WEB-INF subdirectory of
the digilib directory
(/docuserver/www/digitallibrary/WEB-INF).
The only parameter you will have to adjust is the position of the digilib configuration file. The parameter occurs twice in the file and looks like this:
<!-- parameters to the servlet -->
<init-param>
<param-name>config-file</param-name>
<param-value>
/docuserver/www/digitallibrary/WEB-INF/digilib-config.xml
</param-value>
</init-param>
Change the path to point where you installed the configuration files.
Make shure to change the parameter in both places in the config file! It is needed both for the servlet and the JSP pages!
The main configuration for digilib is
digilib-config.xml. It's position is defined by the
config-file init-parameter to the servlets (see
above).
In the configuration file you can set several paths and options. The file looks like this:
<!-- Digilib servlet config file -->
<digilib-config>
<parameter name="debug-level" value="0" />
<!-- Image to be sent to indicate general failure. -->
<parameter name="error-image" value="/docuserver/images/icons/broken.gif" />
<!-- Image to be sent to indicate authorization failure. -->
<parameter name="denied-image" value="/docuserver/images/icons/alert.red.gif" />
<!-- List of directories where images are searched.
The authoritative directory with the high-resolution images
is first in list. -->
<parameter name="basedir-list" value="/docuserver/images:/docuserver/scaled/small" />
<!-- Java class to use for image operations -->
<parameter name="docuimage-class" value="digilib.image.JAIDocuImage" />
<!-- is sending whole image files with mo=file allowed? -->
<parameter name="sendfile-allowed" value="true" />
<!-- Restrict access to authorized users.
User authentication and roles are provided by the servlet container
(see tomcat-users.xml).
Authorization for resources (directories) is evaluated by the servlet
(see auth-file). -->
<parameter name="use-authorization" value="true" />
<!-- Location of XML file with authorization requirements. -->
<parameter name="auth-file" value="/docuserver/www/digitallibrary/WEB-INF/digilib-auth.xml" />
<!-- Part of URL to indicate authenticated access to Tomcat. -->
<parameter name="auth-url-path" value="authenticated/" />
</digilib-config>
You have to adjust the basedir-list parameter to the
directories where your images are installed. You need only one
directory if you do not have prescaled low resolution versions of your
images. The directory with the high-resolution versions must be the
first entry in the list.
You can supply your own images for the "error" and "access denied" messages by the servlet. Standard images will be used if these parameters are undefined.
The auth-file parameter has to point to the
authorization configuration file (see below).
You can specify the Java toolkit implementation with the
docuimage-class parameter. The
ImageLoaderDocuImage might give best performance but
works only with JDK 1.4 and up. JAIDocuImage works with
JDK 1.3 and up.
The digilib access authorization is defined in the file defined by
the auth-file parameter (usually
digilib-auth.xml in WEB-INF).
The file has two parts diglib-paths and
diglib-addresses. It looks like this:
<auth-config>
<digilib-paths>
<!--
A user must supply one of the roles under "role"
to access the directory "name".
Roles under "role" must be separated by comma only (no spaces).
-->
<path name="histast/eastwood-collection" role="eastwood-coll" />
<path name="ptolemaios_geo" role="ptolemaios-geo" />
</digilib-paths>
<digilib-addresses>
<!--
A computer with an ip address that matches "ip"
is automatically granted all roles under "role".
The ip address is matched from the left (in full quads).
Roles under "role" must be separated by comma only (no spaces).
-->
<address ip="127" role="local" />
<address ip="130.92.68" role="eastwood-coll,ptolemaios-geo" />
<address ip="130.92.151" role="ALL" />
</digilib-addresses>
</auth-config>
diglib-paths defines restricted directories and
the roles needed for access. The roles are defined with the users in
tomcat-users.xml (see above). All subdirectories of the
given directories have the same restrictions. All directories not
listed here (and not subdirectories of listed directories) are freely
accessible.
diglib-addresses defines hosts or networks of
computers that are automatically authenticated without username and
password. Hosts can be assigned roles. The special keyword ALL
authorizes for everything. If the role assigned to the computer is not
sufficient to access a resource the user will be asked for username
and password.