-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile
29 lines (21 loc) · 1011 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
28
29
# The Dockerfile is the description of all the commands to run to assemble the image.
# Read about all the commands here: https://docs.docker.com/engine/reference/builder/
# We also have a docker-compose.yml file, which is used to build and run this Docker image.
# Start from the official Node 8 image. https://hub.docker.com/_/node/
FROM node:8
# Disable update check
ENV NO_UPDATE_NOTIFIER=true
# Set the working directory for following commands.
ENV HOME=/tds-community
WORKDIR /tds-community
# Add a user so that we don't run as root:
# https://github.com/telusdigital/reference-architecture/blob/3ff683dd68b247ac9a3febda828105fe52cd9390/delivery/docker.md#root-vs-user-mode
RUN set -ex && \
adduser node root && \
chmod g+w /
# Set the container's user to the newly created one.
USER node
# The entrypoint configures the container to be run as an executable.
# Arguments supplied on the command line will be forwarded onto the entrypoint.
ENTRYPOINT ["npm", "run"]
CMD ["dev:e2e-direct"]