Just use pre-built image to start with:
FROM quay.io/wildfly/wildfly:26.1.3.Final
Use a Bash script to download Wildfly, and configure OS. Assumes you create a host.env config file and a /run/wildfly.env file:
wget https://raw.githubusercontent.com/JeffersonLab/smoothness/main/bash/wildfly/rhel9-setup.sh
chmod +x rhel9-setup.sh
./rhel9-setup.sh host.env
- Install WSL2 if not already installed.
- Download and unzip the distributable Wildfly package.
- Now launch bash from the Terminal with "bash". Notice path starts with
/mnt/c/
- Now run server setup and app setup scripts as described below (perhaps using dos2unix on any
.sh
and.env
files first).
Note: An advantage of using a local workstation installation of Wildfly is that it allows you to easily use an IDE to quickly build, run, and test changes. If running dependencies (services) in Docker (via deps.yaml) then the networking can be tricky. You may need to reference your local instance of Wildfly from within a Docker container. Referencing "localhost" won't work. One solution is to start Wildfly bound to the actual hostname and reference that name (wildfly-26.1.3.Final\bin\standalone.bat -b 0.0.0.0).
Use a Bash script to configure server-wide settings:
wget https://raw.githubusercontent.com/JeffersonLab/wildfly/main/scripts/server-setup.sh
chmod +x server-setup.sh
./server-setup.sh server.env
Note: Wildfly requires a Java Keystore to configure TLS. The script pem-java-keystore.sh may help.
Use a Bash script to configure per-app settings:
wget https://raw.githubusercontent.com/JeffersonLab/wildfly/main/scripts/app-setup.sh
chmod +x app-setup.sh
./app-setup.sh app.env