Skip to content

Instantly share code, notes, and snippets.

@mykhailo-petrenko
Last active September 7, 2023 15:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mykhailo-petrenko/48618b6997d89b80a831902ccc9f1de6 to your computer and use it in GitHub Desktop.
Save mykhailo-petrenko/48618b6997d89b80a831902ccc9f1de6 to your computer and use it in GitHub Desktop.
Error: Failed to launch chrome! spawn .. node_modules/puppeteer/.local-chromium/linux .. /chrome-linux/chrome ENOENT
# Use container with installed chromium and $PUPPETEER_EXECUTABLE_PATH
# https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
FROM node:20.2.0-alpine
RUN apk add --update-cache \
chromium \
nss \
freetype \
harfbuzz \
ca-certificates \
ttf-freefont
# Tell Puppeteer to skip installing Chrome. We'll be using the installed package.
ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment