First, install the Tomcat server packages. Jiglu will work with Tomcat versions 8.0, 8.5 and 9.0. On OpenSuse use:
zypper install tomcat
On Amazon Linux instead use:
Configuration files for Tomcat are normally located in /etc/tomcat or /etc/tomcat8. Changes will need to be made to the following files:
tomcat.conf / tomcat8.conf
Changes need to be made to made to enable headless mode so image processing can be used without a display, to allow encoded slashes in URLs, to disable message compression with web sockets and to set a reasonable memory size. Normally this will be through adding or changing the
Development mode should be turned off for the jsp servlet:
A host definition will need to be added for the server:
<Valve className="org.apache.catalina.valves.RemoteIpValve" />
RemoteIpValve is required to pass through details of the remote IP address for logging purposes. The
ErrorReportValve will prevent details of the server internals being shown to users for malformed requests.
In the connector definition you will want to increase the maximum size for a discarded upload so if users try and upload too large a file they will get an error message rather than having the connection reset by Tomcat, though enforcing a maximum is still a good idea. You may also want to allow compression for scripts and stylesheets:
<Connector port="8080" protocol="HTTP/1.1"
Catalina directory, add a deployment descriptor by creating a directory with the same name as the host name above and inside it adding a
<?xml version='1.0' encoding='utf-8'?>
<Context docBase="/opt/jiglu/webapp" path="">
The host value will need to be that of the machine where the Jiglu server can be found and the RMI port value that of the port number, as found in the Jiglu
To enable Tomcat to start when the server is booted use:
systemctl enable tomcat
Tomcat will be started later in the installation process.