Configuring Tomcat for Codebeamer
This page describes using
Codebeamer with Tomcat. For configuration help with other application servers, such as Oracle Weblogic Server 11g (10.3.2)
get in touch with Intland Software![](../../codebeamer/images/out_756.png)
.
SSL Certificate
Codebeamer is shipped with a self-signed SSL-Certificate from Intland Software. The Port's SSL certificate is configured in the <cb-installation-dir>/tomcat/conf/server.xml file in the section:
<!-- Define an SSL HTTP/1.1 Connector on port 8443 -->
<Connector port="8443"
...
keystoreFile="webapps/cb/config/keystore"
keystorePass="..."
...
/>
To configure the SSL-Certificate, change the attributes keystoreFile and keystorePass, to point to the keystore with the certificate.
Maximum HTTP POST Size
Tomcat by default sets a limit on the maximum size of HTTP POST requests to 2 Mb. In case receiving the error message Post too large, edit the <Connector> element in <cb-installation-dir>/tomcat/conf/server.xml and add an attribute maxPostSize and set a larger value (in bytes) to increase the limit. Setting it to 0 disables the size check.
Using Codebeamer standard HTTP/HTTPS without Root Privilege
Redirecting Port (iptabes)
One way is to use Iptables to redirect ports 80 and 443 to user ports (>1024).
$ /sbin/iptables -A FORWARD -p tcp --destination-port 443 -j ACCEPT
$ /sbin/iptables -t nat -A PREROUTING -j REDIRECT -p tcp --destination-port 443 --to-ports 8443
$ /sbin/iptables -A FORWARD -p tcp --destination-port 80 -j ACCEPT
$ /sbin/iptables -t nat -A PREROUTING -j REDIRECT -p tcp --destination-port 80 --to-ports 8080
$ /sbin/iptables-save or /etc/init.d/iptables save
BSD-based Unix systems such as Mac OS X use a tool similar to Iptables, called IPFW (for Internet Protocol Fire Wall). This tool watches all network packets go by, and can apply rules to affect those packets, such as port-forwarding from port 80 to some other ports such as Tomcat's default 8080. The syntax of the rules is different from those of the Iptables, however, the logic is the same.
E.g.: possible rule for the port-forwarding:
$ sudo ipfw add 100 fwd 127.0.0.1,8080 tcp from any to any 80 in
Using Apache in front of Codebeamer/Tomcat (mod_jk)
In order to run
Codebeamer/Tomcat with non-root privileges and to be able to access
Codebeamer/Tomcat via the standard HTTP/HTTPS ports
80 and
443, set up an Apache Web server with the
Apache Tomcat Connector![](../../codebeamer/images/out_756.png)
(mod_jk) in front of
Codebeamer.
• First, the codebeamer/Tomcat AJP/1.3 port (typically 8009) needs to be activated by editing <cb-installation-dir>/tomcat/conf/server.xml, and removing the comments around the following section:
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443"
acceptCount="200"
maxPostSize="-1"
maxThreads="250"
enableLookups="false"
connectionTimeout="80000"
URIEncoding="UTF-8"
maxSwallowSize="-1"
/>
Next, you have to install and configure the
Installing Apache Webserver (Deprecated).
See also:
Application configuration via environment variables,
Apache Tomcat 9 Configuration Reference![](../../codebeamer/images/out_756.png)