How to install Tomcat7 on Linux Mint


How to install tomcat7 on linux mint is simple.

Run:

sudo apt-get install tomcat7 tomcat7-admin tomcat7-common  

That's it.

Now to configure the users for the mangers.

Open the user file.

sudo vim /etc/tomcat7/tomcat-users.xml  

Make it look like this:

<?xml version='1.0' encoding='utf-8'?>  
<tomcat-users>

<role rolename="manager-gui"/>  
<role rolename="manager-script"/>  
<role rolename="manager"/>  
<role rolename="admin-gui"/>  
<role rolename="admin-script"/>  
<role rolename="admin"/>

<user username="admin" password="admin"
roles="manager-gui,admin-gui,manager,admin,manager-script,admin-script"/>

</tomcat-users>

Then restart tomcat

sudo service tomcat7 restart