-
-
Save navarroaxel/3f44927c9a3e28c25a2b30c244813e07 to your computer and use it in GitHub Desktop.
FROM node:slim | |
# We don't need the standalone Chromium | |
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true | |
# 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 && \ | |
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/* |
@thibaultchazal oh! Google Chrome is only packaged for amd64
, but Chromium and Firefox supports arm64
. You should go for that browsers.
Hi @thibaultchazal,
Try to specify the architecture when building the image. Like this:
$ docker build --platform linux/amd64 . -t your_image_name
I had the same problem on M1 Max and this solved my issue.
This solved it for me. --platform linux/amd64
ERROR: failed to solve: process "/bin/sh -c 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/*" did not complete successfully: exit code: 100
Hi @navarroaxel
I have the exact same error as @Ashwin746544 and I'm also on Mac, with M2 chip to be exact
I have run
docker run -it node:slim bash
and then the commands one by one (the new ones from the 24th) and I have the error about not able to locate google-chrome-stable packageI have tried to debug with apt list and it find one for goog-chrome-stable but it seams it is for amd64 (and my computer is using arm64)
Any clue what to do ?
BTW, I have tried on another machine (not on mac M2) and it works very well ;)