-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
28 lines (24 loc) · 994 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# Dockerfile to run my WAR file
# This uses a base image from jetty, which can run war files...
#FROM jetty:9.3.12-jre8-alpine - lighter weight option, but doesn't include bash and curl for health checking
FROM jetty:latest
# Add our war into the image
ADD ./target/bookingprovider-2.0-SNAPSHOT.war /var/lib/jetty/webapps/ROOT.war
# Says that when it runs, it's port 8080 needs to be available
EXPOSE 8080
# To build the image using this, simply run:
# $docker build -t a2sibookingprovider .
# This creates an image called a2sibookingprovider based on this dockerfile
#
# To run a container based on this image use:
# $docker run -d -p 443:8080 --name bookingprovider a2sibookingprovider
# This creates a running (in the background) container called bookingprovider on port 443.
#
# Browse to http://localhost:443/poc
#
# To stop the running container use:
# $docker stop bookingprovider
#
# To remove the container and image:
# $docker rm bookingprovider
# $docker rmi a2sibookingprovider