forked from garris/BackstopJS
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support arm64 / amd64 arch (garris#1300)
- Loading branch information
Showing
3 changed files
with
52 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,25 @@ | ||
FROM node:16.14.0 | ||
# use bullseye node base, as debian does provide a chromium for arm64 and amd64 flavour | ||
FROM node:16-bullseye | ||
|
||
ARG BACKSTOPJS_VERSION | ||
ARG DEBIAN_FRONTEND=noninteractive | ||
|
||
ENV \ | ||
BACKSTOPJS_VERSION=$BACKSTOPJS_VERSION | ||
ENV BACKSTOPJS_VERSION=$BACKSTOPJS_VERSION | ||
|
||
# Base packages | ||
RUN apt-get update && \ | ||
apt-get install -y git sudo software-properties-common | ||
# install chromium and its deps | ||
RUN apt-get -qq update >/dev/null && apt-get install -qq fonts-liberation chromium >/dev/null | ||
|
||
RUN sudo npm install -g --unsafe-perm=true --allow-root backstopjs@${BACKSTOPJS_VERSION} | ||
|
||
RUN wget https://dl-ssl.google.com/linux/linux_signing_key.pub && sudo apt-key add linux_signing_key.pub | ||
RUN sudo add-apt-repository "deb http://dl.google.com/linux/chrome/deb/ stable main" | ||
|
||
# RUN apt-get -y update && apt-get -y install google-chrome-stable | ||
|
||
# RUN apt-get install -y firefox-esr | ||
|
||
# gconf-service libxext6.... added for https://github.com/garris/BackstopJS/issues/1225 | ||
|
||
RUN apt-get -qqy update \ | ||
&& apt-get -qqy --no-install-recommends install \ | ||
libfontconfig \ | ||
libfreetype6 \ | ||
xfonts-cyrillic \ | ||
xfonts-scalable \ | ||
fonts-liberation \ | ||
fonts-ipafont-gothic \ | ||
fonts-wqy-zenhei \ | ||
libgbm-dev \ | ||
gconf-service libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxss1 libxtst6 libappindicator1 libnss3 libasound2 libatk1.0-0 libc6 ca-certificates fonts-liberation lsb-release xdg-utils wget \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& apt-get -qyy clean | ||
USER root | ||
# skip download, we already have it installed | ||
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true | ||
RUN npm install -g --unsafe-perm=true --allow-root backstopjs@${BACKSTOPJS_VERSION} | ||
RUN rm -rf /var/lib/apt/lists/* \ && apt-get -qq clean >/dev/null | ||
|
||
USER node | ||
|
||
# set executable path | ||
ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium | ||
WORKDIR /src | ||
|
||
ENTRYPOINT ["backstop"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters