Installing Workbench on Tomcat 4.1.x
Scope
This document describes how to setup Tomcat 4.1.x, to be used as a ControlTier server, using a WebDAV repository, a file-based model datastore, and tomcat-users.xml file for authentication and authorization.
These instructions have been tested with Tomcat 4.1.31.
Unpack ControlTier Server Webapp
If you do not have the ControlTier Workbench webapp archive, first download the Workbench itnav-<vers>.war file from the download website. The name of the ControlTier Server webapp is "itnav". Create directory $CATALINA_BASE/webapps/itnav. Copy the itnav.war file to $CATALINA_BASE/webapps/ directory.
mkdir $CATALINA_BASE/webapps/itnav cp /path/to/the/downloaded/itnav.war $CATALINA_BASE/webapps/
Configure Workbench Settings
Workbench datastore configuration information is maintained in a file called bootstrap.properties.
Change the following three settings in $CATALINA_BASE/webapps/itnav/WEB-INF/classes/bootstrap.properties For the ngps.workbench.backend.fs.base, choose a directory where you would like the model data stored.
ngps.workbench.backend.type = fs ngps.workbench.backend.fs.base = /var/ctier/rdfdata
Ensure the auth.properties is configured like below. (This is how it should come by default, too). Edit $CATALINA_BASE/webapps/itnav/WEB-INF/classes/auth.properties
ngps.workbench.auth.type=default
Update Tomcat Libraries
cp $CATALINA_BASE/webapps/itnav/WEB-INF/lib/xerces-2.6.1.jar $CATALINA_HOME/common/endorsed/xercesImpl.jar cp $CATALINA_BASE/webapps/itnav/WEB-INF/lib/xml-apis-2.6.1.jar $CATALINA_HOME/common/endorsed/xml-apis.jar cp $CATALINA_BASE/webapps/itnavE/WEB-INF/lib/xalan-2.6.0.jar $CATALINA_HOME/common/endorsed/xalan.jar
Update Tomcat's Execution Path
Depending on the installation path of Graphviz and the dot executable, the PATH environment variable may need to be updated in Tomcat's startup script. The following unix/win32 examples add Graphviz to Tomcat's execution path. For unix, edit $CATALINA_HOME/bin/startup.sh:
PATH=/usr/local/bin:$PATH
export PATH
For Win32, edit %CATALINA_HOME%\bin\startup.bat:
set Path=C:\Program Files\ATT\Graphviz\bin;%Path%
Configure Tomcat Realm
For Workbench to use tomcat-users.xml for authentication and authorization, add the following fragment to the $CATALINA_BASE/conf/server.xml:
<Realm className="org.apache.catalina.realm.UserDatabaseRealm"
debug="0" resourceName="UserDatabase"/>
Next, edit the CATALINA_BASE/conf/tomcat-users.xml and define users.
<tomcat-users>
<role rolename="user"/>
<role rolename="architect"/>
<role rolename="manager"/>
<role rolename="admin"/>
<!--
To add users for Workbench, add entries similar to the user1,user2 and user3 entries below.
All Workbench users need to be in at least the "user" role.
-->
<user username="user1" password="user1pass" roles="user"/>
<user username="user2" password="user2pass" roles="user,admin"/>
<user username="user3" password="user3pass" roles="user,admin,architect"/>
<!-- A user with the "manager" role can be used for the /manager tomcat web application. -->
<!-- <user username="manager" password="manager" roles="manager"/>-->
</tomcat-users>
Configure Tomcat HTTP Port
By default, Tomcat runs on port 8080. To change this configuration setting locate the 'Connector' tag and change the port attribute:
<Connector className="org.apache.catalina.connector.http.HttpConnector"
port="8080" address="0.0.0.0" minProcessors="5" maxProcessors="75"
enableLookups="true" redirectPort="8443"
acceptCount="10" debug="0" connectionTimeout="60000"/>
Configure Tomcat's WebDAV webapp
By default, the webdav servlet is configured as read-only. Set the readonly parameter from true to false in the CATALINA_BASE/webapps/webdav/WEB-INF/web.xml:
<servlet>
<servlet-name>webdav</servlet-name>
<servlet-class>org.apache.catalina.servlets.WebdavServlet</servlet-class>
<init-param>
<param-name>debug</param-name>
<param-value>0</param-value>
</init-param>
<init-param>
<param-name>listings</param-name>
<param-value>true</param-value>
</init-param>
<!-- Uncomment this to enable read and write access -->
<init-param>
<param-name>readonly</param-name>
<param-value>false</param-value>
</init-param>
<!--load-on-startup>1</load-on-startup-->
</servlet>
Configure webdav BASIC authentication and the ControlTier user, admin, and architect roles:
<security-constraint>
<web-resource-collection>
<web-resource-name>Administrative</web-resource-name>
<url-pattern>/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>user</role-name>
<role-name>admin</role-name>
<role-name>architect</role-name>
</auth-constraint>
</security-constraint>
<login-config>
<auth-method>BASIC</auth-method>
<realm-name>JNDIRealm</realm-name>
</login-config>
Start Tomcat
Tomcat should now be ready to run Workbench. To start using Workbench, first start (or restart) the Tomcat server with Tomcat's bin/startup.(sh|bat) scripts, and point your browser to http://localhost:8080/itnav.

