forked from innoq/hotshot
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
39 lines (29 loc) · 1.06 KB
/
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
30
31
32
33
34
35
36
37
38
39
FROM node:12-buster-slim
RUN apt-get update \
&& apt-get install -y wget gnupg \
&& wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
&& sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' \
&& apt-get update \
&& apt-get install -y google-chrome-unstable \
fonts-ipafont-gothic \
fonts-wqy-zenhei \
fonts-thai-tlwg \
fonts-kacst \
fonts-freefont-ttf \
--no-install-recommends \
&& apt-get install -y fonts-noto dumb-init \
&& rm -rf /var/lib/apt/lists/*
RUN groupadd -r pptruser && useradd -r -g pptruser -G audio,video pptruser \
&& mkdir -p /home/pptruser/Downloads \
&& chown -R pptruser:pptruser /home/pptruser \
&& mkdir /app \
&& chown -R pptruser:pptruser /app
ENTRYPOINT ["dumb-init", "--"]
USER pptruser
WORKDIR /app
COPY --chown=pptruser:pptruser . .
ENV NODE_ENV=production
ENV MAX_AGE=86400
RUN yarn --cache-folder ./ycache && yarn install && rm -rf ./ycache
EXPOSE 5000
CMD ["node", "app.js"]