This document describes how to configure Tomcat manager functionality including:
Host Manager
Refer to Apache Tomcat Manager App HOW-TO
Copy manager web application folder(webapps/manager) from the Tomcat source to your webapps directory.
Copy host-manager web application folder(webapps/host-manager) from the Tomcat source to your webapps directory.
Configure UserDatabaseRealm in $CATALINA_BASE/conf/server.xml. Usually you can keep the existing server.xml content from the Tomcat source.
Configure Tomcat users.
Edit $CATALINA_BASE/conf/tomcat-users.xml
<role rolename="admin-gui"/> <role rolename="manager-gui"/> <user username="userABC" password="passABC" roles="admin-gui,manager-gui"/>
You can also define different users to login to “admin-gui” and “manager-gui” by using 2 derivatives.
Now you can start Tomcat server.
Use web browser to connect to:
Web manager –> http://localhost:8080/manager/
Host manager –> http://localhost:8080/host-manager/
The login window should popup for you to login.
Optional
If you like to use virtual host to set up the Tomcat manager gui, follow this.
Edit $CATALINA_BASE/conf/server.xml
<Host appBase="" autoDeploy="true" name="h1.test.com" unpackWARs="true"> <!-- Access log processes all example. Documentation at: /docs/config/valve.html Note: The pattern used is equivalent to using pattern="common" --> <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs" pattern="%h %l %u %t "%r" %s %b" prefix="h1.test.com_access_log." suffix=".txt"/> </Host>
Create file $CATALINA_BASE/conf/Catalina/h1.test.com/manager.xml
<Context privileged="true" antiResourceLocking="false" docBase="${catalina.home}/webapps/manager"> </Context>
Change file permission so Tomcat can access it.
Now start Tomcat server. Use web browser to connect to
Web manager –> http://h1.test.com:8080/manager/
Host manager –> http://h1.test.com:8080/host-manager/