-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.hapi
29 lines (20 loc) · 885 Bytes
/
Dockerfile.hapi
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
FROM node:8-alpine
WORKDIR /usr/share/node/app
ARG PORT=80
ENV PORT $PORT
ENV NODE_ENV production
RUN apk add --update python python-dev py-pip build-base && \
pip install --upgrade pip && \
pip install virtualenv && \
rm -rf /var/cache/apk/*
COPY package.json /tmp/package.json
COPY yarn.lock /tmp/yarn.lock
RUN cd /tmp && yarn && yarn cache clean
RUN mkdir -p /usr/share/node/app/logs && \
cp -a /tmp/node_modules /usr/share/node/app
COPY server.packed.js ./
COPY pages ./pages
COPY handlebars ./handlebars
COPY static ./static
CMD [ "node", "server.packed.js" ]
HEALTHCHECK --timeout=0.1s --start-period=2s CMD wget -qO- http://localhost:3000/health || exit 1