users@glassfish.java.net

Hide admin console port and add a context-root

From: <glassfish_at_javadesktop.org>
Date: Tue, 23 Mar 2010 14:05:30 PDT

Hi All,

During my deployment of glassfish i have encountered a problem. I have the need to access the admin console but hidding the adminport for example:

www.mydomain.com:4848 should be like www.mydomain.com/gadmin

under apache i have a proxy pointing like this:

/gadmin http://localhost:4848/gadmin

in this way the port number will be redirected thru the port 80 and will be hidden in the url. To have this working i had to change the "context-root" param in domain.xml file under glassfish/domain/domain1/config

<application context-root="" location="${com.sun.aas.installRootURI}/lib/install/applications/__admingui" directory-deployed="true" name="__admingui" object-type="system-admin">

<application context-root="/gadmin" location="${com.sun.aas.installRootURI}/lib/install/applications/__admingui" directory-deployed="true" name="__admingui" object-type="system-admin">

Everything works fine except for some links in the main menu for example the link "Java Message Service" points to

http://www.mydomain.com/gadmin/gadmin/jms/jmsService.jsf?configName=server-config

instead of

http://www.mydomain.com/gadmin/jms/jmsService.jsf?configName=server-config

this same happens with some others, apparently the context-root is getting appended twice during url parsing.

Can anybody help on this or does anybody know how to hide the adminport in another way?

Regards
[Message sent by forum member 'luzyano']

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