GlassFish tip - Have your application be the root application

This blog has moved to alexismp.wordpress.com
Follow the link for the most up-to-date version of this blog entry.

I've had the question several times about how to install a web application at the root of GlassFish (the use-case being probably to put into production an application on an intranet). Well, as discussed here it's as simple as deploying your application with a "/" web context which can be done using the web Admin console (set the "Context Root:" field to "/") or the command line :

% asadmin deploy --contextroot "/" your-webapp.war

or making sure the sun-web.xml deployment descriptor contains a context-root element set to /.

The alternate solution is to use the notion of default web module for a given virtual server just like the web admin console is the default for port 4848.

Change the HTTP listen port to default 80 (with appropriate privileges on Unix) and you're off to the simplest possible URL for your users.

Comments:

Post a Comment:
Comments are closed for this entry.
About

This blog has moved

Alexis Moussine-Pouchkine's Weblog

GlassFish - Stay Connected

Search

Archives
« avril 2014
lun.mar.mer.jeu.ven.sam.dim.
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today
Blogroll

No bookmarks in folder

News

No bookmarks in folder