This is the 19th day of Payara Advent Calendar 2016.
Payara has a Docker image, which is published on the Docker Hub.
From this, the command to run the application using the Payara Micro image is as follows.
docker run -d --name=helloworld -p 8080:8080 \ -v `pwd`/helloworld/build/libs:/opt/payara/deployments:ro \ payara/micro java -jar /opt/payara/payara-micro.jar \ --deploy /opt/payara/deployments/helloworld.war
I am trying to access port 8080 with
-v mounts the directory where the WAR file is stored (
build / libs in the above) to
/ opt / payara / deployments.
After that, specify the image (
payara / micro) and write the
java command to move Payara Micro.
As mentioned above, I tried to move Payara Micro, which can be easily operated with just one JAR, more easily using Docker (I personally find it easier because I don't need to fetch the JAR). ..
Docker Hub also has
payara / server-full,
payara / server-web, and
payara / microprofile, so I'll play with them a little more.
I have an app on GitHub that just makes Hello world to try Payara Micro on Docker, so please try it if you like.