Saturday, October 20, 2018

Wildfly/JBoss Application Server Setup Guide

1. Download from http://download.jboss.org/wildfly/12.0.0.Final/wildfly-12.0.0.Final.zip
   Note: Wildfly is a community version of JBoss Application Server. If you want an enterprise version, look for JBoss EAP(license required) from Redhat.

2. Install Wildfly 12.0 by unzip the binary package to a local folder, c:\wildfly-12.0.0-Final.

3. Set up environment in Windows System Environment or a batch file
     c:\> SET JBOSS_HOME=c:\wildfly-12.0.0-Final
     c:\> SET PATH=%PATH%;%JBOSS_HOME%/bin

4. Start up Wildfly/JBoss Server
     c:\wildfly-12.0.0-Final\bin> standalone.bat
     NOTE: if there is any port numbers already in use, update the port number in %JBOSS_HOME%/standalone/configuration/standalone.xml (the socket-binding section at the bottom of the configuration file)

5. Check logs in %JBOSS_HOME%/standalone/log

6. Test Wildfly/JBoss Application Server
     In web browser, access http://localhost:8080/, a default Wildfly page should show up.

7. (Hot) deploy a web application archive package (*.war file) to the Wildfly/JBoss standalone instance.
     Copy the .war file (e.g. WebDesignDemo.war) into %JBOSS_HOME%/standalone/deployments while the application server is running. The server will unpack the application into a folder with the name of the .war file.
     The application context name is normally same as the .war file name. The HTTP URL is http://localhost:8080/<Context Name> (e.g. http://localhost:8080/WebDesignDemo).
     Without specifying a page name in the URL, the server will look at the default home page, e.g. index.html or index.jsp in the application folder.
     To check if the application deployment is successful, go to the deployment folder, you should see a file with the extension of .deployed. If failed, open the file and investigate the error message.

8. Shut down Wildfly/JBoss Application Server
     Just press Ctrl+C in the application server console window, or close the MS-DOS console with the running server.
     Note: if you have any strange issues when shutting down the server, use Windows Task Manager to kill the corresponding java.exe process.

No comments:

Post a Comment