Link to home
Start Free TrialLog in
Avatar of stiavetti
stiavettiFlag for United States of America

asked on

Where to put WAR file? for top level URL

iI want my Tomcat app to run at  http://127.0.0.1/index.jsp instead of http://127.0.0.1/appname/index.jsp.

Right now it lives in the C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\appname  folder, but I want it to see "appname" in the URL.

appname (obviously) is the name of the application. Seems like an easy one, but if the points are nto right, let me know.

what er the "gotchas" and how can I tell if the code it relative ( besides trying it)
Avatar of Mick Barry
Mick Barry
Flag of Australia image

can your post your context xml

> Where to put WAR file?

rename it to ROOT.war

Avatar of stiavetti

ASKER

First...thank you for taking interest. Guys like yourself make the IT world go around.

Here is the: context xml


 <?xml version="1.0" encoding="UTF-8" ?>
- <!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.


  -->
- <!--  The contents of this file will be loaded for each web application
  -->
- <Context>
- <!--  Default set of monitored resources
  -->
  <WatchedResource>WEB-INF/web.xml</WatchedResource>
- <!--  Uncomment this to disable session persistence across Tomcat restarts
  -->
- <!--
    <Manager pathname="" />
   

  -->
  </Context>
you should just be able to rename the war and redeploy it to t=omcat

Ok, I am going to try this tonight...possibly tommorow, and let you know. Once again, thanks for sticking with me..
This did not actually work, but I believe your answer to be correct.  I ended up just putting in a redirect instead, from the root...seems like a deficiency in the product.

So points are awarded, sorry for the delay.
ASKER CERTIFIED SOLUTION
Avatar of Mick Barry
Mick Barry
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Close enough for goverment work - "Objects Rocks!"