Midtier 7.6 Linux Install
By makeaweli
- 2 minutes read - 339 wordsInstalling the .war file using tomcat.
Install tomcat
Use yum to install the following packages:
Enable the startup service:
Configure tomcat
We need to set some env variables so tomcat knows where the midtier libs are. Normally, this file is named catalina.sh. But, the rpm package installs it here: /usr/bin/dtomcat5.
Add the following after the comments:
Install the war file
There’s various ways to install a war file. The easiest method is to copy it to the webapps tomcat directory. Make sure to rename the war file to arsys.war. By default, tomcat will configure your app path to the name of the war file. Let’s be consistent and use arsys as your path root.:
Start tomcat:
In your browser, navigate to the following URL:
SSL certificate
Certificate setup
Install mod_ssl:
Create directories for certificates and keys:
Create the server key
Use the ssl password in tome:
Convert the key to passwordless so apache can start itself without prompting for the key’s password:
Create the certificate request
When creating the request, it’s important that the OU field is the exact fully qualified domain that you intend to serve your requests.
Copy and paste the certifcate request to the sysadmin in charge of creating certificates. Make sure to ask for a base-64 encoded certificate.
Intstall the signed certificate
Copy and paste the signed certificate into a new file:
Apache configuration
Apache needs to be configured with support for ssl and proxying of the tomcat server.
Install the ssl package:
Modify the ssl conf:
Tomcat SSL configuration
Tomcat needs to be aware of the proxy. Find a similar block of text as the following, modifying only the last line as follows: [textarea] vi /etc/tomcat5/server.xml <!– Define a non-SSL HTTP/1.1 Connector on port 8080 –>
[/textarea]
Tomcat7 Disable Cross Site Scripting
Tomcat 7 ships with XSS support enabled by default. Due to our use of a proxy, midtier throws errors because the cookies are being intercepted by the XSS. Here’s how to turn it off:
Make sure to add ‘useHttpOnly’ attribute to the context element.