WildFly (formally JBoss) is a lightweight, fast, and highly optimized Java-based application runtime that allows you to develop great applications from a single IDE. WildFly is cross-platform with a robust dashboard which makes changing a setting in the application server, and configuration very simple and quick. No need to browse unnecessary pages to customize your environment to fit your needs. For more about WildFly and other related documentation, please visit its homepage. When you’re ready to setup WildFly on Ubuntu, follow the steps below:

Install OpenJDK

WildFly is written in Java and requires Java JDK to function. you either install the official Oracle Java JDK or use the open-source alternative called OpenJDK. For this tutorial, we’re going to be installing the open-source version of Java. To do that, run the commands below: After installing OpenJDK above, you can run the commands below to validate that it is installed. You should see similar lines below: If you see the lines above, then Java is installed and ready.

Setup WildFly User

Since this is an application server, it’s usually recommended to use a dedicated service account. Run the commands below to create a WildFly service account to manage the server. Run the commands below to create an account and group called wildfly. After that, continue below to download and configure WildFly packages.

Download and Configure WildFly

Now that you’ve installed Java JDK and created a service account for WildFly, run the commands below to download WildFly packages. At the time of this post, the current version is 16.0.0. Final. You can check its download page to get the latest when they become available. Using wget command, you can easily download it using the commands below: After downloading, run the commands below to create the WildFly folder in the /opt directory and change its ownership to the WildFly service account. Next, create the WildFly service folder in the /etc/ directory by running the commands below. Then copy WildFly configuration files, and executables into the newly created directory above, and make its scripts in the /etc/wildfly/bin directory executable. After that copy its systemd file to the /etc/systemd/system/ directory by running the commands below Now you can use the commands below to stop, start and enable WildFly services to automatically start at boot time. To check it started, run the commands below: You should see its status service info as shown below: Now that you’ve downloaded and configured the WildFly service, run the commands below to create a user account that will connect and manage the app server web console. You’ll be prompted. type a to continue. Type in a new username and create a password: Type yes for the other options and complete the setup. WildFly should be installed and ready. Open your browser and browse to the server hostname or IP address followed by port #8080 (its default port). The admin console is at: Out of the box, the server console is restricted to the local server only. If you’d like to connect from a remote location, Open its configuration file by running the commands below. Then add the highlighted line in the file and save. After that run the script below to create an account to log on to the admin console. You’ll be prompted to enter the account and password you created above. Next, open the launch script And edit the highlighted lines, Exit and save the file. Restart the service. Next, open the WildFly service by running the commands below. Then edit the highlighted line and save. Save the file and exit. Reload systemd and restart. That’s it! You can now access the admin console remotely. Conclusion: This post showed you how to install WildFly on Ubuntu 20.04 | 18.04. If you find any error above, please use the form below to report. You may also like the post below: