Mod_JK Apache - site redirection

Posted on 2011-10-13
Last Modified: 2012-05-12
Tomcat running on 8080 -- default install
Apache using vhost
Mod_jk working fine

Instead of working like this:  -->mod_jk loads tomcat default page (equiv to
I'd like it to go to:  --> modjk loads equiv to

So essentially I'd like to remove the subfolder off the url and go straight to the app.

Make sense?

I'm sure I just have to add something to my server.xml file but not sure where to start as I have not done a whole lot in tomcat before.

Question by:Tigger996
    LVL 9

    Accepted Solution


    Set  the path "" in a Context element within <Host> in server.xml on Tomcat.
    <Context docBase="/var/lib/tomcat6/webapps/search/" path="" reloadable="true>

    Author Comment

    Ok, that works great.  But what will happen when I add other domains to that machine (through apache)
    so I'd like what we have above...

    Then I'll have another app that sits in /mynewapp
    And I'll want that pointed to


    Author Comment

    I figured it out.  Thanks for your help!

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    As Wikipedia explains 'robots.txt' as -- the robot exclusion standard, also known as the Robots Exclusion Protocol or robots.txt protocol, is a convention to prevent cooperating web spiders and other web robots from accessing all or part of a websit…
    Configure Web Service (server application) I. Configure security for Web Services methods First, we need to protect Session bean which implements the service: 1. Open EJB deployment descriptor (ejb-jar.xml) in the EJB project that contains you…
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.

    755 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now