Skip to content
This repository has been archived by the owner on Jun 22, 2024. It is now read-only.

Commit

Permalink
Add chromium image
Browse files Browse the repository at this point in the history
  • Loading branch information
fhoeben committed Dec 17, 2023
1 parent 56fc22a commit 47c5257
Show file tree
Hide file tree
Showing 35 changed files with 623 additions and 13 deletions.
12 changes: 12 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ updates:
interval: daily
time: '08:00'
open-pull-requests-limit: 99
- package-ecosystem: docker
directory: "/StandaloneChromium"
schedule:
interval: daily
time: '08:00'
open-pull-requests-limit: 99
- package-ecosystem: docker
directory: "/StandaloneFirefox"
schedule:
Expand Down Expand Up @@ -36,6 +42,12 @@ updates:
interval: daily
time: '08:00'
open-pull-requests-limit: 99
- package-ecosystem: docker
directory: "/NodeChromium"
schedule:
interval: daily
time: '08:00'
open-pull-requests-limit: 99
- package-ecosystem: docker
directory: "/"
schedule:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/test-video.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ jobs:
with:
name: chrome_video
path: ./tests/videos/chrome_video.mp4
- name: Upload recorded Chromium video
uses: actions/upload-artifact@v4
with:
name: chromium_video
path: ./tests/videos/chromium_video.mp4
- name: Upload recorded Edge video
uses: actions/upload-artifact@v4
with:
Expand Down
60 changes: 55 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,12 @@ all: hub \
chrome \
edge \
firefox \
chromium \
docker \
standalone_chrome \
standalone_edge \
standalone_firefox \
standalone_chromium \
standalone_docker \
video

Expand Down Expand Up @@ -71,6 +73,9 @@ chrome_dev:
chrome_beta:
cd ./NodeChrome && docker build $(BUILD_ARGS) $(FROM_IMAGE_ARGS) --build-arg CHROME_VERSION=google-chrome-beta -t $(NAME)/node-chrome:beta .

chromium: node_base
cd ./NodeChromium && docker build $(BUILD_ARGS) $(FROM_IMAGE_ARGS) -t $(NAME)/node-chromium:$(TAG_VERSION) .

edge: node_base
cd ./NodeEdge && docker build $(BUILD_ARGS) $(FROM_IMAGE_ARGS) -t $(NAME)/node-edge:$(TAG_VERSION) .

Expand Down Expand Up @@ -113,6 +118,9 @@ standalone_chrome_dev: chrome_dev
standalone_chrome_beta: chrome_beta
cd ./Standalone && docker build $(BUILD_ARGS) --build-arg NAMESPACE=$(NAME) --build-arg VERSION=beta --build-arg BASE=node-chrome -t $(NAME)/standalone-chrome:beta .

standalone_chromium: chromium
cd ./Standalone && docker build $(BUILD_ARGS) $(FROM_IMAGE_ARGS) --build-arg BASE=node-chromium -t $(NAME)/standalone-chromium:$(TAG_VERSION) .

standalone_edge: edge
cd ./Standalone && docker build $(BUILD_ARGS) $(FROM_IMAGE_ARGS) --build-arg BASE=node-edge -t $(NAME)/standalone-edge:$(TAG_VERSION) .

Expand All @@ -128,11 +136,14 @@ video:

# https://github.com/SeleniumHQ/docker-selenium/issues/992
# Additional tags for browser images
tag_and_push_browser_images: tag_and_push_chrome_images tag_and_push_firefox_images tag_and_push_edge_images
tag_and_push_browser_images: tag_and_push_chrome_images tag_and_push_firefox_images tag_and_push_edge_images tag_and_push_chromium_images

tag_and_push_chrome_images:
./tag_and_push_browser_images.sh $(VERSION) $(BUILD_DATE) $(NAMESPACE) $(PUSH_IMAGE) chrome

tag_and_push_chromium_images:
./tag_and_push_browser_images.sh $(VERSION) $(BUILD_DATE) $(NAMESPACE) $(PUSH_IMAGE) chromium

tag_and_push_edge_images:
./tag_and_push_browser_images.sh $(VERSION) $(BUILD_DATE) $(NAMESPACE) $(PUSH_IMAGE) edge

Expand All @@ -149,10 +160,12 @@ tag_latest:
docker tag $(NAME)/event-bus:$(TAG_VERSION) $(NAME)/event-bus:latest
docker tag $(NAME)/node-base:$(TAG_VERSION) $(NAME)/node-base:latest
docker tag $(NAME)/node-chrome:$(TAG_VERSION) $(NAME)/node-chrome:latest
docker tag $(NAME)/node-chromium:$(TAG_VERSION) $(NAME)/node-chromium:latest
docker tag $(NAME)/node-edge:$(TAG_VERSION) $(NAME)/node-edge:latest
docker tag $(NAME)/node-firefox:$(TAG_VERSION) $(NAME)/node-firefox:latest
docker tag $(NAME)/node-docker:$(TAG_VERSION) $(NAME)/node-docker:latest
docker tag $(NAME)/standalone-chrome:$(TAG_VERSION) $(NAME)/standalone-chrome:latest
docker tag $(NAME)/standalone-chromium:$(TAG_VERSION) $(NAME)/standalone-chromium:latest
docker tag $(NAME)/standalone-edge:$(TAG_VERSION) $(NAME)/standalone-edge:latest
docker tag $(NAME)/standalone-firefox:$(TAG_VERSION) $(NAME)/standalone-firefox:latest
docker tag $(NAME)/standalone-docker:$(TAG_VERSION) $(NAME)/standalone-docker:latest
Expand All @@ -168,10 +181,12 @@ release_latest:
docker push $(NAME)/event-bus:latest
docker push $(NAME)/node-base:latest
docker push $(NAME)/node-chrome:latest
docker push $(NAME)/node-chromium:latest
docker push $(NAME)/node-edge:latest
docker push $(NAME)/node-firefox:latest
docker push $(NAME)/node-docker:latest
docker push $(NAME)/standalone-chrome:latest
docker push $(NAME)/standalone-chromium:latest
docker push $(NAME)/standalone-edge:latest
docker push $(NAME)/standalone-firefox:latest
docker push $(NAME)/standalone-docker:latest
Expand All @@ -187,10 +202,12 @@ tag_major_minor:
docker tag $(NAME)/event-bus:$(TAG_VERSION) $(NAME)/event-bus:$(MAJOR)
docker tag $(NAME)/node-base:$(TAG_VERSION) $(NAME)/node-base:$(MAJOR)
docker tag $(NAME)/node-chrome:$(TAG_VERSION) $(NAME)/node-chrome:$(MAJOR)
docker tag $(NAME)/node-chromium:$(TAG_VERSION) $(NAME)/node-chromium:$(MAJOR)
docker tag $(NAME)/node-edge:$(TAG_VERSION) $(NAME)/node-edge:$(MAJOR)
docker tag $(NAME)/node-firefox:$(TAG_VERSION) $(NAME)/node-firefox:$(MAJOR)
docker tag $(NAME)/node-docker:$(TAG_VERSION) $(NAME)/node-docker:$(MAJOR)
docker tag $(NAME)/standalone-chrome:$(TAG_VERSION) $(NAME)/standalone-chrome:$(MAJOR)
docker tag $(NAME)/standalone-chromium:$(TAG_VERSION) $(NAME)/standalone-chromium:$(MAJOR)
docker tag $(NAME)/standalone-edge:$(TAG_VERSION) $(NAME)/standalone-edge:$(MAJOR)
docker tag $(NAME)/standalone-firefox:$(TAG_VERSION) $(NAME)/standalone-firefox:$(MAJOR)
docker tag $(NAME)/standalone-docker:$(TAG_VERSION) $(NAME)/standalone-docker:$(MAJOR)
Expand All @@ -203,10 +220,12 @@ tag_major_minor:
docker tag $(NAME)/event-bus:$(TAG_VERSION) $(NAME)/event-bus:$(MAJOR).$(MINOR)
docker tag $(NAME)/node-base:$(TAG_VERSION) $(NAME)/node-base:$(MAJOR).$(MINOR)
docker tag $(NAME)/node-chrome:$(TAG_VERSION) $(NAME)/node-chrome:$(MAJOR).$(MINOR)
docker tag $(NAME)/node-chromium:$(TAG_VERSION) $(NAME)/node-chromium:$(MAJOR).$(MINOR)
docker tag $(NAME)/node-edge:$(TAG_VERSION) $(NAME)/node-edge:$(MAJOR).$(MINOR)
docker tag $(NAME)/node-firefox:$(TAG_VERSION) $(NAME)/node-firefox:$(MAJOR).$(MINOR)
docker tag $(NAME)/node-docker:$(TAG_VERSION) $(NAME)/node-docker:$(MAJOR).$(MINOR)
docker tag $(NAME)/standalone-chrome:$(TAG_VERSION) $(NAME)/standalone-chrome:$(MAJOR).$(MINOR)
docker tag $(NAME)/standalone-chromium:$(TAG_VERSION) $(NAME)/standalone-chromium:$(MAJOR).$(MINOR)
docker tag $(NAME)/standalone-edge:$(TAG_VERSION) $(NAME)/standalone-edge:$(MAJOR).$(MINOR)
docker tag $(NAME)/standalone-firefox:$(TAG_VERSION) $(NAME)/standalone-firefox:$(MAJOR).$(MINOR)
docker tag $(NAME)/standalone-docker:$(TAG_VERSION) $(NAME)/standalone-docker:$(MAJOR).$(MINOR)
Expand All @@ -219,10 +238,12 @@ tag_major_minor:
docker tag $(NAME)/event-bus:$(TAG_VERSION) $(NAME)/event-bus:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/node-base:$(TAG_VERSION) $(NAME)/node-base:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/node-chrome:$(TAG_VERSION) $(NAME)/node-chrome:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/node-chromium:$(TAG_VERSION) $(NAME)/node-chromium:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/node-edge:$(TAG_VERSION) $(NAME)/node-edge:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/node-firefox:$(TAG_VERSION) $(NAME)/node-firefox:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/node-docker:$(TAG_VERSION) $(NAME)/node-docker:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/standalone-chrome:$(TAG_VERSION) $(NAME)/standalone-chrome:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/standalone-chromium:$(TAG_VERSION) $(NAME)/standalone-chromium:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/standalone-edge:$(TAG_VERSION) $(NAME)/standalone-edge:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/standalone-firefox:$(TAG_VERSION) $(NAME)/standalone-firefox:$(MAJOR_MINOR_PATCH)
docker tag $(NAME)/standalone-docker:$(TAG_VERSION) $(NAME)/standalone-docker:$(MAJOR_MINOR_PATCH)
Expand All @@ -237,10 +258,12 @@ release: tag_major_minor
@if ! docker images $(NAME)/event-bus | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/event-bus version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/node-base | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/node-base version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/node-chrome | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/node-chrome version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/node-chromium | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/node-chromium version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/node-edge | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/node-edge version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/node-firefox | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/node-firefox version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/node-docker | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/node-docker version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/standalone-chrome | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/standalone-chrome version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/standalone-chromium | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/standalone-chromium version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/standalone-edge | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/standalone-edge version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/standalone-firefox | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/standalone-firefox version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
@if ! docker images $(NAME)/standalone-docker | awk '{ print $$2 }' | grep -q -F $(TAG_VERSION); then echo "$(NAME)/standalone-docker version $(TAG_VERSION) is not yet built. Please run 'make build'"; false; fi
Expand All @@ -253,10 +276,12 @@ release: tag_major_minor
docker push $(NAME)/event-bus:$(TAG_VERSION)
docker push $(NAME)/node-base:$(TAG_VERSION)
docker push $(NAME)/node-chrome:$(TAG_VERSION)
docker push $(NAME)/node-chromium:$(TAG_VERSION)
docker push $(NAME)/node-edge:$(TAG_VERSION)
docker push $(NAME)/node-firefox:$(TAG_VERSION)
docker push $(NAME)/node-docker:$(TAG_VERSION)
docker push $(NAME)/standalone-chrome:$(TAG_VERSION)
docker push $(NAME)/standalone-chromium:$(TAG_VERSION)
docker push $(NAME)/standalone-edge:$(TAG_VERSION)
docker push $(NAME)/standalone-firefox:$(TAG_VERSION)
docker push $(NAME)/standalone-docker:$(TAG_VERSION)
Expand All @@ -269,10 +294,12 @@ release: tag_major_minor
docker push $(NAME)/event-bus:$(MAJOR)
docker push $(NAME)/node-base:$(MAJOR)
docker push $(NAME)/node-chrome:$(MAJOR)
docker push $(NAME)/node-chromium:$(MAJOR)
docker push $(NAME)/node-edge:$(MAJOR)
docker push $(NAME)/node-firefox:$(MAJOR)
docker push $(NAME)/node-docker:$(MAJOR)
docker push $(NAME)/standalone-chrome:$(MAJOR)
docker push $(NAME)/standalone-chromium:$(MAJOR)
docker push $(NAME)/standalone-edge:$(MAJOR)
docker push $(NAME)/standalone-firefox:$(MAJOR)
docker push $(NAME)/standalone-docker:$(MAJOR)
Expand All @@ -285,10 +312,12 @@ release: tag_major_minor
docker push $(NAME)/event-bus:$(MAJOR).$(MINOR)
docker push $(NAME)/node-base:$(MAJOR).$(MINOR)
docker push $(NAME)/node-chrome:$(MAJOR).$(MINOR)
docker push $(NAME)/node-chromium:$(MAJOR).$(MINOR)
docker push $(NAME)/node-edge:$(MAJOR).$(MINOR)
docker push $(NAME)/node-firefox:$(MAJOR).$(MINOR)
docker push $(NAME)/node-docker:$(MAJOR).$(MINOR)
docker push $(NAME)/standalone-chrome:$(MAJOR).$(MINOR)
docker push $(NAME)/standalone-chromium:$(MAJOR).$(MINOR)
docker push $(NAME)/standalone-edge:$(MAJOR).$(MINOR)
docker push $(NAME)/standalone-firefox:$(MAJOR).$(MINOR)
docker push $(NAME)/standalone-docker:$(MAJOR).$(MINOR)
Expand All @@ -301,10 +330,12 @@ release: tag_major_minor
docker push $(NAME)/event-bus:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/node-base:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/node-chrome:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/node-chromium:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/node-edge:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/node-firefox:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/node-docker:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/standalone-chrome:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/standalone-chromium:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/standalone-edge:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/standalone-firefox:$(MAJOR_MINOR_PATCH)
docker push $(NAME)/standalone-docker:$(MAJOR_MINOR_PATCH)
Expand All @@ -315,7 +346,9 @@ test: test_chrome \
test_chrome_standalone \
test_firefox_standalone \
test_edge \
test_edge_standalone
test_edge_standalone \
test_chromium \
test_chromium_standalone


test_chrome:
Expand All @@ -324,6 +357,12 @@ test_chrome:
test_chrome_standalone:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/bootstrap.sh StandaloneChrome

test_chromium:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/bootstrap.sh NodeChromium

test_chromium_standalone:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/bootstrap.sh StandaloneChromium

test_edge:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/bootstrap.sh NodeEdge

Expand All @@ -338,9 +377,9 @@ test_firefox_standalone:

# This should run on its own CI job. There is no need to combine it with the other tests.
# Its main purpose is to check that a video file was generated.
test_video: video hub chrome firefox edge
test_video: video hub chrome firefox edge chromium
# Running a few tests with docker-compose to generate the videos
for node in NodeChrome NodeFirefox NodeEdge ; do \
for node in NodeChrome NodeFirefox NodeEdge NodeChromium ; do \
cd ./tests || true ; \
echo VIDEO_TAG=$(FFMPEG_TAG_VERSION)-$(BUILD_DATE) > .env ; \
echo TAG=$(TAG_VERSION) >> .env ; \
Expand All @@ -349,6 +388,10 @@ test_video: video hub chrome firefox edge
echo BROWSER=chrome >> .env ; \
echo VIDEO_FILE_NAME=chrome_video.mp4 >> .env ; \
fi ; \
if [ $$node = "NodeChromium" ] ; then \
echo BROWSER=chromium >> .env ; \
echo VIDEO_FILE_NAME=chromium_video.mp4 >> .env ; \
fi ; \
if [ $$node = "NodeEdge" ] ; then \
echo BROWSER=edge >> .env ; \
echo VIDEO_FILE_NAME=edge_video.mp4 >> .env ; \
Expand All @@ -364,6 +407,7 @@ test_video: video hub chrome firefox edge
docker run -v $$(pwd):$$(pwd) -w $$(pwd) $(FFMPEG_BASED_NAME)/ffmpeg:$(FFMPEG_BASED_TAG) -v error -i ./tests/videos/chrome_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) $(FFMPEG_BASED_NAME)/ffmpeg:$(FFMPEG_BASED_TAG) -v error -i ./tests/videos/firefox_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) $(FFMPEG_BASED_NAME)/ffmpeg:$(FFMPEG_BASED_TAG) -v error -i ./tests/videos/edge_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) $(FFMPEG_BASED_NAME)/ffmpeg:$(FFMPEG_BASED_TAG) -v error -i ./tests/videos/chromium_video.mp4 -f null - 2>error.log

chart_setup_env:
./tests/charts/make/chart_setup_env.sh
Expand All @@ -380,14 +424,18 @@ chart_build:
chart_test: chart_test_template \
chart_test_chrome \
chart_test_firefox \
chart_test_edge
chart_test_edge \
chart_test_chromium

chart_test_template:
./tests/charts/bootstrap.sh

chart_test_chrome:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/charts/make/chart_test.sh NodeChrome

chart_test_chromium:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/charts/make/chart_test.sh NodeChromium

chart_test_firefox:
VERSION=$(TAG_VERSION) NAMESPACE=$(NAMESPACE) ./tests/charts/make/chart_test.sh NodeFirefox

Expand All @@ -403,6 +451,7 @@ chart_test_parallel_autoscaling:
build \
ci \
chrome \
chromium \
edge \
firefox \
docker \
Expand All @@ -415,6 +464,7 @@ chart_test_parallel_autoscaling:
node_base \
release \
standalone_chrome \
standalone_chromium \
standalone_edge \
standalone_firefox \
standalone_docker \
Expand Down
2 changes: 1 addition & 1 deletion NodeBase/start-xvfb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ if [ "${START_XVFB:-$SE_START_XVFB}" = true ] ; then
--server-args="-screen 0 ${GEOMETRY} -fbdir /var/tmp -dpi ${SCREEN_DPI} -listen tcp -noreset -ac +extension RANDR" \
/usr/bin/fluxbox -display ${DISPLAY}
else
echo "Xvfb and Fluxbox won't start. Chrome/Firefox/Edge can only run in headless mode. Remember to set the 'headless' flag in your test."
echo "Xvfb and Fluxbox won't start. Chrome/Firefox/Edge/Chromium can only run in headless mode. Remember to set the 'headless' flag in your test."
fi
55 changes: 55 additions & 0 deletions NodeChromium/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
ARG NAMESPACE
ARG VERSION
ARG AUTHORS
FROM ${NAMESPACE}/node-base:${VERSION}
LABEL authors=${AUTHORS}

USER root

#============================================
# Chromium and chromedriver from Debian
# Available versions at: https://packages.debian.org/search?keywords=chromium
#============================================
COPY chromium.pref /etc/apt/preferences.d/chromium.pref

ARG DEBIAN_VERSION=bullseye
ARG REPO_FILE=/etc/apt/sources.list.d/debian.list
ARG KEY_SERVER=keyserver.ubuntu.com
ARG DEBIAN_KEY_LOCATION=/usr/share/keyrings/debian
ARG CHROMIUM_VERSION=120.0.6099.109-1~deb11u1
ARG CHROMEDIVER_VERSION=${CHROMIUM_VERSION}
RUN mkdir /home/seluser/.gnupg && mkdir -p ${DEBIAN_KEY_LOCATION} \
&& gpg --no-default-keyring --keyring ${DEBIAN_KEY_LOCATION}/${DEBIAN_VERSION}.gpg \
--keyserver ${KEY_SERVER} \
--recv-keys 0E98404D386FA1D9 \
&& echo "deb [signed-by=${DEBIAN_KEY_LOCATION}/${DEBIAN_VERSION}.gpg] http://deb.debian.org/debian ${DEBIAN_VERSION} main" \
> ${REPO_FILE} \
&& gpg --no-default-keyring --keyring ${DEBIAN_KEY_LOCATION}/${DEBIAN_VERSION}-updates.gpg \
--keyserver ${KEY_SERVER} \
--recv-keys 6ED0E7B82643E131 \
&& echo "deb [signed-by=${DEBIAN_KEY_LOCATION}/${DEBIAN_VERSION}-updates.gpg] http://deb.debian.org/debian ${DEBIAN_VERSION}-updates main" \
>> ${REPO_FILE} \
&& gpg --no-default-keyring --keyring ${DEBIAN_KEY_LOCATION}/security-${DEBIAN_VERSION}.gpg \
--keyserver ${KEY_SERVER} \
--recv-keys 112695A0E562B32A \
&& echo "deb [signed-by=${DEBIAN_KEY_LOCATION}/security-${DEBIAN_VERSION}.gpg] http://deb.debian.org/debian-security ${DEBIAN_VERSION}-security main contrib non-free" \
>> ${REPO_FILE} \
&& apt-get update -qqy \
&& apt-get -qqy --no-install-recommends install chromium=${CHROMIUM_VERSION} chromium-driver=${CHROMEDIVER_VERSION} \
&& rm ${REPO_FILE} \
&& rm -rf /home/seluser/.gnupg ${DEBIAN_KEY_LOCATION}/ /var/lib/apt/lists/* /var/cache/apt/*

#=================================
# Chromium Launch Script Wrapper
#=================================
COPY wrap_chromium_binary /opt/bin/wrap_chromium_binary
RUN /opt/bin/wrap_chromium_binary

USER ${SEL_UID}

#============================================
# Dumping Browser information for config
#============================================
RUN echo "chrome" > /opt/selenium/browser_name
RUN chromium --version | awk '{print $2}' > /opt/selenium/browser_version
RUN echo "\"goog:chromeOptions\": {\"binary\": \"/usr/bin/chromium\"}" > /opt/selenium/browser_binary_location
14 changes: 14 additions & 0 deletions NodeChromium/chromium.pref
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Note: 2 blank lines are required between entries
Package: *
Pin: release a=eoan
Pin-Priority: 500

Package: *
Pin: origin "deb.debian.org"
Pin-Priority: 300

# Pattern includes 'chromium', 'chromium-browser' and similarly
# named dependencies:
Package: chromium*
Pin: origin "deb.debian.org"
Pin-Priority: 700
Loading

0 comments on commit 47c5257

Please sign in to comment.