Deploying CCRC WAN servers on Apache Tomcat
Overview
The IBM® DevOps CCRC WAN servers provide the ClearTeam® Explorer with access to DevOps Code ClearCase® repositories and support for DevOps Code ClearCase web views and automatic views. The ClearCase CCRC WAN servers can be deployed either on IBM WebSphere or Apache Tomcat.
Tomcat is an open source Java application server provided by Apache. This topic highlights the deployment on a Tomcat server. To deploy on IBM WebSphere, refer to the documentation for that product.
Environment
- Operating system
- Windows or Linux server, refer to the supported platforms list for ClearCase.
- Apache Tomcat version
- Tomcat 9.x 64-bit and 10.0.27 or later 64-bit
Installing Tomcat
SSL/TLS setup
To use HTTPS connection with Tomcat, review the SSL/TLS Configuration documentation on the Tomcat website at https://tomcat.apache.org/tomcat-9.0-doc/ssl-howto.html.
To configure the ClearTeam Explorer (CTE) client, follow the ClearCase documentation and associated technote 240547.
Post installation
After installation, ensure that both the JAVA_HOME and CATALINA_HOME environment variables are set correctly.
To allow access to the web manager, you need to add roles and users to Tomcat. The usernames/passwords configuration depends on which Realm implementation you are using (see https://tomcat.apache.org/tomcat-9.0-doc/config/realm.html). By default, it uses an XML-format file that can be edited with any text editor, stored at $CATALINA_BASE/conf/tomcat-users.xml. This is explained in detail in the Tomcat documentation available at https://tomcat.apache.org/tomcat-9.0-doc/manager-howto.html#Configuring_Manager_Application_Access.
<user username="devuser" password="password" roles="manager-gui,manager-status"/>
Installing ClearCase and the CCRC WAN server
- On Windows, select the Server Components/View Server
feature
- On UNIX, select the ClearCase Server-only
installation featureNote: When using Tomcat, you do not need to select the CCRC WAN server and Automatic View WAN Server components. These components are for using IBM WebSphere.
If you use PAM authentication in your environment, you need to configure it for ClearCase. Create a ClearCase configuration file for pam.d; see technote 345521. On a RHEL7 system, you can also copy /etc/pam.d/login to /etc/pam.d/clearcase.
Deploying the CCRC WAN server application to Tomcat
- On Windows: C:/Program Files/DevOps/Code/ClearCase/web
- On Linux: /opt/devops/code/clearcase/web
- ccrc.war
- rview.war
In the next section, when the context path needs to be configured, it refers to the path the application will be accessed via HTTP. That is, to use the URL http://localhost:8080/ccrc, the context path field needs to be /ccrc.
There are several ways to deploy it to Tomcat. Remember that both WAR files need to be deployed.
Deploy manually
In your Tomcat instance, copy the two WAR files into the following directory: $CATALINA_HOME/webapps
- If the instance is running, Tomcat unpacks the archives and configures their context path.
- If the instance is not running, both will be deployed and configured the next time it is started.
Deploy using Tomcat Manager
You can use the management dashboard to deploy the application. Access the manager dashboard on the system at the following URL: http://localhost:8080/manager
A. Deploy directory or WAR file located on server
- In the WAR or Directory path field, enter the absolute URL/path to the WAR file as it appears on your server and include the .war extension (for example, C:/apps/ccrc.war). On Windows you can use either forward or backward slashes in the path.
- In the Context Path field, include a forward slash before your entry (/ccrc and /rview, respectively for each WAR file)
- Click the Deploy button. The page will reload and you should see a
message informing you the application has been deployed:
After deployment, the application will also appear in the Applications section of the page.
B. WAR file to deploy
- Click the Choose file button.
- Navigate to the location of the WAR file and select it.
- Click the Deploy button.
INFO: Deployment of web application archive \path\to\ccrc has finished in x,yyy ms
Configuration
ClearCase post configuration
- The following directories exist and are set with 0777 permissions:
- /var/adm/devops/clearcase/ccweb
- /var/adm/devops/clearcase/ccdav
- /var/adm/atria is a symlink to /var/adm/devops/clearcase
CCRC temporary directory (ccrcTempDir)
This variable specifies a directory where temporary files are stored. The pathname must be a directory on the CM server host in which all users of the DevOps Code ClearCase remote client have permission to create and delete files (permission 777 on UNIX). By default, temporary files are stored in the pathname specified in the value of the TMP or TEMP environment variable, if they exist. This must be updated for both web view and automatic view.
- On Windows: C:/Program Files/DevOps/Code/ClearCase/config/ccrc/server.conf
- On Linux: /opt/devops/code/clearcase/config/ccrc/server.conf
- On Windows: C:/Program Files/DevOps/Code/ClearCase/config/rview/rview_server.conf
- On Linux: /opt/devops/code/clearcase/config/rview/rview_server.conf
ccrcTempDir=
Configuring WAN server logging
The default Tomcat configuration does not provide session and some other log information for the ClearCase WAN server. In order to enable those logs, the Tomcat logging.properties file must be modified to add a log configuration for the WAN server.
- Open tomcat installation directory/conf/logging.properties in a text editor.
- Add these lines to the
file:
com.ibm.rational.cc.common.logging.CCRCLogger.level=INFO com.ibm.rational.cc.common.logging.LogHandler.formatter=java.util.logging.SimpleFormatter com.ibm.rational.cc.common.logging.LogHandler.pattern = ${catalina.base}/logs/CCRCLogger%g.log com.ibm.rational.cc.common.logging.LogHandler.limit = 20000000 com.ibm.rational.cc.common.logging.LogHandler.count = 20 com.ibm.rational.cc.common.logging.LogHandler.append = true
- Restart Tomcat.
Accessing the CCRC/RVIEW administration page
<role rolename="Administrator"/> <user name="devuser" password="password" roles="Administrator,manager-gui,manager-status"/>
Both URLs list the current settings for each server.
Connection to the CCRC WAN server
CCRC WAN server maintenance
To upgrade to a new version, un-deploy the current two applications (ccrc and rview) and deploy the new WAR files.