Tomcat – How to set default URL Path in Tomcat 6

mod-proxytomcat

I have installed Tomcat 6 and Jenkins. I can connect to it via http://localhost/jenkins, but i want to access it directly via http://localhost. How can I archive this?
My complete setup includes a host computer with Apache2 installed and it routes several subdomains to virtual machines. So if it is easier to do it in Apache, I could do it too, but I would prefer the first solution.

I am completely new to the Java and Tomcat world, so this might be pretty easy, but I didn't got it.

Best Answer

You need to use URL rewriting. These two posts from stackoverflow: link 1, link 2 suggest to use URLrewriteFilter.

Any easier option may be to run your webapp as ROOT webapp in tomcat. See this post on how to do so.

Related Topic