mirror of
https://github.com/hcengineering/platform.git
synced 2024-12-29 22:44:36 +03:00
24 lines
993 B
Docker
24 lines
993 B
Docker
|
|
||
|
FROM node:20
|
||
|
|
||
|
# We don't need the standalone Chromium
|
||
|
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true
|
||
|
# Set executable path for puppeteer
|
||
|
ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome-stable
|
||
|
|
||
|
# Install Google Chrome Stable and fonts
|
||
|
# Note: this installs the necessary libs to make the browser work with Puppeteer.
|
||
|
RUN apt-get update && apt-get install gnupg wget -y dumb-init && \
|
||
|
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/*
|
||
|
|
||
|
WORKDIR /usr/src/app
|
||
|
|
||
|
COPY bundle/bundle.js ./
|
||
|
RUN npm install --ignore-scripts=false --verbose bufferutil utf-8-validate @mongodb-js/zstd snappy --unsafe-perm
|
||
|
|
||
|
CMD [ "dumb-init", "node", "bundle.js" ]
|