Skip to content
Grant Burgess edited this page Aug 24, 2018 · 3 revisions

sudo apt-get install -y tomcat7

sudo apt-get install -y tomcat7-admin

sudo sh -c 'echo "TOMCAT_HOME=\"/var/lib/tomcat7/\"" >> /etc/environment'

sudo sh -c 'echo "CATALINA_HOME=\"/usr/share/tomcat7\"" >> /etc/environment'

sudo sh -c 'echo "CATALINA_BASE=\"/var/lib/tomcat7/\"" >> /etc/environment'

source /etc/environment

Edit the tomcat-users.xml file in /var/lib/tomcat7/conf directory to add roles, usernames and passwords.

Eg, Using Vim

sudo vim /var/lib/tomcat7/conf/tomcat-users.xml

Example tomcat-users.xml