users@glassfish.java.net

Re: server log exposed on the web ?

From: Jan Luehe <Jan.Luehe_at_Sun.COM>
Date: Tue, 09 Feb 2010 10:53:17 -0800

On 02/ 9/10 04:26 AM, Felipe Gaścho wrote:
> is there an easy way of exposing the Glassfish log on the web ?
>
> * I don't want to expose the admin port.. due to security reasons.. I
> want only to show the log...(eventually password protected)
>
>
One way would be to configure the path to the server.log as an alternate
docroot, either at the virtual server or web application level.

For example, you could bundle the attached sun-web.xml with some foo.war
(after adjusting the value of the "dir" attribute of the
"alternatedocroot_1"
property to point to the "logs" directory of your own GlassFish
installation),
deploy foo.war, and then access this URL:

  localhost:8080/foo/server.log


Jan