The sample application must be available before you start this task. To download the sample, see Obtaining a Sample Application. At least one Enterprise Server domain must be started before you deploy the sample application.
Use the asadmin deploy command.
The general form for the command is:
as-install/bin/asadmin deploy war-name |
To deploy the hello.war sample, the command is:
as-install/bin/asadmin deploy sample-dir/hello.war |
Access the hello application by typing the following URL in your browser:
http://localhost:8080/hello |
The application's start page is displayed, and you are prompted to type your name.
Hi, my name is Duke. What's yours? |
Type your name and click Submit.
The application displays a customized response, giving you a personal Hello.
See deploy(1) for more information about the deploy command.
See the Sun GlassFish Enterprise Server v3 Application Deployment Guide for more information about deploying applications from the command line.