Re: [servlex] install servlex in root context

On 20 February 2015 at 20:06, Paul Tyson wrote:

  Hi,

> Is it possible to install servlex in the root context of tomcat?

  Yes.

> I have configured a tomcat context "/" to go to servlex.

  So it is the root webapp?  So it is in [tomcat]/webapps/ROOT/?

> My webapps.xml has a single <webapp> with @root="/". The servlex
> WebappsParser complains this is not valid.

> My goal is to make "servlex" disappear from the url, and only respond to
> urls defined by my webapp. That is, "http://myhost.com/myapp" instead of
> "http://myhost.com/servlex/myapp" (or any alias for "servlex").

  I think there is a bit of confusion here.  Servlex is a Java web
application, that you can deploy on Tomcat (for instance).  It is
itself a web container for the EXPath webapp spec.  Meaning that you
can deploy such EXPath webapps in Servlex.

  Since you have deployed Servlex at the root of your Tomcat instance,
Servlex itself is available at http://myhost.com/ (and everything
underneath...)  If you want the webapps you deploy in Servlex to be
available as http://myhost.com/myapp/, then ou can deploy them as
usual.  @root="/" is not what you want, rather root="myapp".

  There are 2 levels of context roots: those of Tomcat (one is
assigned to Servlex, here the special "root" one).  And those of
Servlex itself, one being assigned to your webapp (in this case, it
should be "myapp").

  Does that solve your problem?

  Regards,

-- 
Florent Georges
http://fgeorges.org/
http://h2oconsulting.be/

Received on Sunday, 22 February 2015 18:48:47 UTC