There are several alternatives available for installing and removing applications:
- Geronimo Administration Console
- #Deployer tool (command line)
- #Hot deployment (command line)
When you package your application you may include the deployment plan within the package or not. At deployment time, Geronimo will look for the geronimo-web.xml and web.xml deployment plans (or geronimo-application.xml or geronimo-application-client.xml depending the type of application) in the WEB-INF directory within you packaged application. If Geronimo can not find those descriptors it will attempt to deploy the application using defaults. If using defaults fails you will have to provide a deployment plan either repackaged in the application or providing an external deployment plan, in the following sections we will discuss further these alternatives.
Geronimo Administration Console
To install a new application via the Geronimo Administration Console the Install New Applications portlet is available by selecting Deploy New on the Console Navigation menu on the left hand side. This portlet also allows you to start automatically the application right after it was deployed.
As mentioned before, for this example we will be using the simple JSP HelloWorld sample created in the Quick start - Apache Geronimo for the impatient section. In that section however we used the --inPlace deployment option, in other words we did not have the need to package the application into a WAR file. To create the WAR file type the following command from the <app_home> directory
jar -cvf HelloWorld.war
*
This WAR already has included in the package the deployment plans.
Back in the Geronimo Administration Console, from the Install New Applications portlet click on Browse to specify the path to the HelloWorld.war
in the Archive: section. Make sure the Start app after install checkbox is selected (by default is checked) and then click on Install.
You should see the " The application was successfully deployed.
" and " The application was successfully started.
" confirmation messages on the top of the portlet.
Another way to verify that the application has been successfully installed and started is by checking the Installed Web Applications portlet which is available by selecting Web App WARs on the Console Navigation menu on the left hand side. You should see the application listed as hello and with the status running.
Since the application we installed is HelloWold.WAR we use this portlet, when you install an EAR you would check the status using the Installed Application EARs portlet available by selecting Application EARs on the Console Navigation menu on the left hand side. The installation procedure is the same for both WAR and EAR applications.
To remove the applications through the Geronimo Administration Console you would use these two portlets, either the Installed Web Applications or the Installed Application EARs portlets depending on the application to uninstall.
For our example, access the Installed Web Applications portlet and click on Uninstall for the Component Name listing sample.applications/HelloWorldApp/2.0/war
. This will stop the application first and then uninstall it. The confirmation message " Uninstalled application
" should be listed at the bottom of the portlet.
These are the basic steps for installing and uninstalling applications via the Geronimo Administration Console, the following two sections will focus on the command line options.