Glassfish Application URL
I've just installed Glassfish
Web Profile (Open source edition) on my VPS. I have deployed my application successfully on domain1. Now t开发者_JS百科he application is accessible on http://localhost/myapplication
How can I config the server in a way my app will be accessible on address: http://localhost
Quoted from my own answer to a similar question:
Option 1: You can set one of your webapps as default. This can be done with the admin console:
Configuration --> Virtual Servers --> server
Then select your default web application from the drop-down menu. If your webserver port is 8080, you can start your application now by:
http://hostname:8080
instead of http://hostname:8080/webapp
Notice that "server" is the name of Glassfish's default virtual server. If you configured a different virtual server for your webapp you need to change it accordingly.
Furthermore regarding this source, there might be some problems with JDBCRealms.
Option 2: You could also deploy your default webapp to "/" instead of "/webapp" but I think the first option is more flexible.
精彩评论