• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Default Web Application

 
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

I have successfully deployed a web application on Tomcat5.0. Now when I enter http://localhost/ I get the Tomcat default page and if I enter http://localhost/myapp/ I get my application.

Is it possible to make Tomcat load my app when the user enters the http://localhost/? (that is set a default web application)

regards,
Sim085
 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
modify /conf/server.xml
 
Simon Joseph Aquilina
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks

I had givin a look to the server.xml file before however I could not understand what I need to change.

Could you give me a hint on what needs to be changed? or the whole file needs to be modified?

thanks and regards,
Sim085
 
Simon Joseph Aquilina
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am sory to post again. However I have been searching in the server.xml file but can not understand what I need to change.

I also tried using the tomcat managment system (which comes automatically when I enter http://localhost/).

What needs to be change from the server.xml file so that my web application will be loaded as default when entering http://localhost/?

thanks and regards,
Sim085
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The simplest way to do this is to rename your app to ROOT and remove the current (default) app with that name.
 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Simon,

Try this.

Give this within the <Host></Host> element in the conf/server.xml.

<Context path="" docBase="yourAppName" debug="0"/>

Hope it helps.
 
Simon Joseph Aquilina
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you very much for the replies. I used the what Reshma sugests (Thanks). However, how can I now access the Tomcat manager?

Also wanted to ask (curiosity) what is the best option? Rename your application as 'ROOT' or else enter that change Reshma sugested.

Thanks again for all the help

Regards,
Sim085
[ August 31, 2006: Message edited by: Simon Joseph Aquilina ]
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Also wanted to ask (curiosity) what is the best option? Rename your application as 'ROOT' or else enter that change Reshma sugested.



I prefer renaming my app to ROOT as being the simplest and having no chance of a typo getting into the xml file.
Bill
 
Simon Joseph Aquilina
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks I will keep the root option in mind.

However I have a further problem on how to access the Tomcat Admin Console from the web. This was very helpfull to restart the application when needed since it allowed the me to restart the applications remotly (without having to go physically on the server).

How is it possible to acces this? I tried renaming the root folder, but did not have any luck.

Regards,
Sim085
 
Switching from electric heat to a rocket mass heater reduces your carbon footprint as much as parking 7 cars. Tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic