-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.worker.local
32 lines (27 loc) · 1.09 KB
/
Dockerfile.worker.local
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
FROM --platform=linux/amd64 node:19.3.0 AS base
# We don't need the standalone Chromium
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true
# install libvips
RUN apt-get update && apt-get install -y libvips
# install chromium for puppeteer
RUN apt-get update && apt-get install gnupg wget -y && \
wget --quiet --output-document=- https://dl-ssl.google.com/linux/linux_signing_key.pub | gpg --dearmor > /etc/apt/trusted.gpg.d/google-archive.gpg && \
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 google-chrome-stable -y --no-install-recommends && \
rm -rf /var/lib/apt/lists/*
FROM base AS copy
WORKDIR /home/node
COPY src/core ./core
WORKDIR /home/node/app
COPY src/server/package.json ./
COPY src/server/yarn.lock ./
COPY src/server/src ./src
RUN yarn install --non-interactive --immutable
FROM copy AS dev
COPY src/server/tsconfig.json ./
COPY src/server/tsconfig.build.json ./
COPY src/server/serve-worker.ts ./
COPY src/server/nodemon.worker.json ./
RUN yarn cp:core
CMD yarn dev:worker