You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Stefano Nichele <st...@gmail.com> on 2008/11/08 21:44:17 UTC

default web app

Hi ALL,
I'm very afraid posting this question since I think it's very common, 
but I was not able to find any useful answer.

I have Tomcat running with just my application. Under <tomcat>/webapps 
there is just my web application (let's say 'myapp').

Now I would like that http://localhost:8080/ will be served by my 
application, so I would like that my application runs as default web 
application.

I don't have any restriction so I can deploy it as directory or as war; 
the only restriction is that I can't rename it in ROOT.

I tried a lot of combinations in the context.xml file or creaing a new 
context file under <tomcat>/catalina/localhost (also with ROOT.xml) 
without success.

Anyone could help me ?

Thanks a lot
ste


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: default web app

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Stefano Nichele [mailto:stefano.nichele@gmail.com]
> Subject: Re: default web app
>
> If I have an application "appA" that serves
> http://localhost:8080/appA, is there a way to
> have it serving also http://localhost:8080/case2 ?

You can use a valve (specific to Tomcat) or a filter (supported by all servlet containers) to forward or redirect requests to another webapp.  You can also install a dummy webapp for the secondary context that does the forward or redirect to the primary.

Look here for an open source ready-to-wear filter that should do what you need:
http://tuckey.org/urlrewrite/

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: default web app

Posted by Stefano Nichele <st...@gmail.com>.
I don't want to use two different virtual hosts, it seems too complicated
(even if I agree that it's not soo complicated in general).

The only way I found it's creating a ROOT.xml file under
<tomcat>/conf/catalina/localhost and putting my webapp in a directory
different from <tomcat>/webapps.
This is a shame, since anyone looks there for web applications.

I would change my question:
If I have an application "appA" that serves http://localhost:8080/appA, is
there a way to have it serving also http://localhost:8080/case2 ?
Cheers
ste
On Sat, Nov 8, 2008 at 2:52 PM, Serge Fonville <se...@gmail.com>wrote:

> Perhaps you should use virtual hosts then.
>
> Regards,
>
> Serge Fonville
>
> On Sat, Nov 8, 2008 at 11:34 PM, Stefano Nichele
> <st...@gmail.com>wrote:
>
> > Since in some case I must install others applications that I can't check
> it
> > and maybe someones of that is ROOT; in such case, I would like just to
> > change some "configuration" files instead of renaming the whole
> application.
> > I know that it's a strange requirement, but that is.
> >
> > ste
> >
> >
> > Caldarale, Charles R wrote:
> >
> >> From: Stefano Nichele [mailto:stefano.nichele@gmail.com]
> >>> Subject: default web app
> >>>
> >>> the only restriction is that I can't rename it in ROOT.
> >>>
> >>>
> >>
> >> Why not?  That's the simplest thing to do.
> >>
> >>  - Chuck
> >>
> >>
> >> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
> >> MATERIAL and is thus for use only by the intended recipient. If you
> received
> >> this in error, please contact the sender and delete the e-mail and its
> >> attachments from all computers.
> >>
> >> ---------------------------------------------------------------------
> >> To start a new topic, e-mail: users@tomcat.apache.org
> >> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> >> For additional commands, e-mail: users-help@tomcat.apache.org
> >>
> >>
> >>
> >>
> >
> >
> >
> > ---------------------------------------------------------------------
> > To start a new topic, e-mail: users@tomcat.apache.org
> > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: users-help@tomcat.apache.org
> >
> >
>

Re: default web app

Posted by Serge Fonville <se...@gmail.com>.
Perhaps you should use virtual hosts then.

Regards,

Serge Fonville

On Sat, Nov 8, 2008 at 11:34 PM, Stefano Nichele
<st...@gmail.com>wrote:

> Since in some case I must install others applications that I can't check it
> and maybe someones of that is ROOT; in such case, I would like just to
> change some "configuration" files instead of renaming the whole application.
> I know that it's a strange requirement, but that is.
>
> ste
>
>
> Caldarale, Charles R wrote:
>
>> From: Stefano Nichele [mailto:stefano.nichele@gmail.com]
>>> Subject: default web app
>>>
>>> the only restriction is that I can't rename it in ROOT.
>>>
>>>
>>
>> Why not?  That's the simplest thing to do.
>>
>>  - Chuck
>>
>>
>> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
>> MATERIAL and is thus for use only by the intended recipient. If you received
>> this in error, please contact the sender and delete the e-mail and its
>> attachments from all computers.
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>>
>>
>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

Re: default web app

Posted by Stefano Nichele <st...@gmail.com>.
Since in some case I must install others applications that I can't check 
it and maybe someones of that is ROOT; in such case, I would like just 
to change some "configuration" files instead of renaming the whole 
application.
I know that it's a strange requirement, but that is.

ste

Caldarale, Charles R wrote:
>> From: Stefano Nichele [mailto:stefano.nichele@gmail.com]
>> Subject: default web app
>>
>> the only restriction is that I can't rename it in ROOT.
>>     
>
> Why not?  That's the simplest thing to do.
>
>  - Chuck
>
>
> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>   



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: default web app

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Stefano Nichele [mailto:stefano.nichele@gmail.com]
> Subject: default web app
>
> the only restriction is that I can't rename it in ROOT.

Why not?  That's the simplest thing to do.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org