diff --git a/01-docker/01-docker/EXERCISE-01.md b/01-docker/01-docker/EXERCISE-01.md index ad911b3..497e390 100644 --- a/01-docker/01-docker/EXERCISE-01.md +++ b/01-docker/01-docker/EXERCISE-01.md @@ -57,7 +57,7 @@ EXPOSE 80 Notes about the _Dockerfile_ (refer to the [Dockerfile reference](https://docs.docker.com/reference/builder/)) for more details): -- `FROM` specifies the base image to build our image upon (_node:10.11.0-alpine_ contains the NodeJS runtime) +- `FROM` specifies the base image to build our image upon (_node:15.4.0-alpine_ contains the NodeJS runtime) - `COPY` simply copies a file from the host file system to the image filesystem - `EXPOSE` identifies the network ports the container will listen on - `CMD` specifies the executable to run when a container is started from the image (we are using the _exec_ form) diff --git a/01-docker/01-docker/solution/Dockerfile b/01-docker/01-docker/solution/Dockerfile index 2c44fe4..d63a8d6 100644 --- a/01-docker/01-docker/solution/Dockerfile +++ b/01-docker/01-docker/solution/Dockerfile @@ -1,6 +1,10 @@ -FROM node:10.11.0-alpine -RUN npm install express redis +FROM node:15.4.0-alpine + COPY files/ /files/ -COPY webui.js / +COPY webui.js /files/webui.js + +WORKDIR /files +RUN npm install express redis + CMD ["node", "webui.js"] EXPOSE 80