Windows DatabaseebooksStatistical Information

LLE10250 : Howto deploy a glassfish webapp so it will be the default web application

Symptom:

You do not want the context-root to be include in the web URL

Cause:

Glassfish adds the name of the web application to the URL by default so urls look like http://webservername:8080/webappname

Solution:

You can deploy the application to the virtual server and set it to the default web module for this server in the Admin Console. To accomplish this you go to the configuration -> virtual servers -> server and select your application from the default web module dropdown box.

Now you can access your application by using the http://localhost:8080 URL directly.

Sometimes this might cause problems with applications using jdbcrealms. In this case you might try an alternative and deploy directly to "/".

This can be done with the command:

asadmin deploy --contextroot "/" warfile.war

In your management console you can see the difference between the two deployments. The latter has the parameter context-root set to "/" under applications and no default-web module under virtual servers.

Disclaimer:

The information provided in this document is intended for your information only. Lubby makes no claims to the validity of this information. Use of this information is at own risk!
Copyright © 2004-2011 Lubby (V3.0.10 Aug 2011)
Sponsored by Keskon.
Statistical information by Google Analytics