users@glassfish.java.net

Re: GlassFish v2 alternate/additional rootpath

From: <glassfish_at_javadesktop.org>
Date: Fri, 11 Jan 2008 16:46:31 PST

That should be easy. You can leverage the existing virtual server named "server", and add the following alternate docroot to it, as follows:

asadmin set [...] server.http-service.virtual-server.server.property.alternatedocroot_1="from=/user_document/* dir=/"

This is on Solaris and assumes the presence of a directory "/user_document/" containing the file "test.pdf", to follow your example.

On Windows, the following should do:

asadmin set [...] server.http-service.virtual-server.server.property.alternatedocroot_1="from=/user_document/* dir=c:\"

Notice that after executing the above command, no server restart is necessary.

Jan
[Message sent by forum member 'jluehe' (jluehe)]

http://forums.java.net/jive/thread.jspa?messageID=253505