In this recipe, you will learn how to run WildFly in a Docker container by creating a Dockerfile
, which describes how the image should be composed. To go through this recipe, you need to have a working Docker installation, along with a Fedora 21 image; if you don't have these installed, please follow the first recipe in this chapter.
In this recipe, you will need an internet connection to download WildFly directly from the container. Also, we will need a Java web application to test our WildFly installation. If you want, you can use one of my projects from my GitHub account, at https://github.com/foogaro/wildfly-cookbook.git.
You can git-clone
the repository or just download it as a ZIP archive:
Place the source at
~/WFC/github
.There you will find a project called
docker-example
. To compile the project, run the following commands:$ cd ~/WFC/github $ cd wildfly-cookbook $ cd docker-example $ mvn clean package
In the
target
folder generated by Maven, you...