Skip to content

Commit

Permalink
Merge branch 'trunk' into ubuntu-jammy
Browse files Browse the repository at this point in the history
  • Loading branch information
diemol authored Nov 10, 2023
2 parents 78802f9 + 6b7356b commit cc13ab1
Show file tree
Hide file tree
Showing 50 changed files with 1,053 additions and 429 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,6 @@ body:
attributes:
label: Docker Selenium version (tag)
description: What version of Docker Selenium are you using?
placeholder: 4.11.0-20230801? Please use the full tag, avoid "latest"
placeholder: 4.15.0-20231108? Please use the full tag, avoid "latest"
validations:
required: true
4 changes: 2 additions & 2 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ jobs:
matrix:
use-random-user: [false, true]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Output Docker info
run: docker info
- name: Set up Python 3.8
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: 3.8
- name: Get branch name (only for push to branch)
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
persist-credentials: false
fetch-depth: 0
Expand Down Expand Up @@ -51,25 +51,25 @@ jobs:
DOCKER_USERNAME: ${{secrets.DOCKER_USERNAME}}
DOCKER_PASSWORD: ${{secrets.DOCKER_PASSWORD}}
- name: Deploy new images
uses: nick-invision/retry@943e742917ac94714d2f408a0e8320f2d1fcafcd # v2
uses: nick-invision/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2
with:
timeout_minutes: 20
max_attempts: 3
command: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make release
- name: Tag images as latest
uses: nick-invision/retry@943e742917ac94714d2f408a0e8320f2d1fcafcd # v2
uses: nick-invision/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2
with:
timeout_minutes: 20
max_attempts: 3
command: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make tag_latest
- name: Deploy latest tag
uses: nick-invision/retry@943e742917ac94714d2f408a0e8320f2d1fcafcd # v2
uses: nick-invision/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2
with:
timeout_minutes: 20
max_attempts: 3
command: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make release_latest
- name: Tag browser images
uses: nick-invision/retry@943e742917ac94714d2f408a0e8320f2d1fcafcd # v2
uses: nick-invision/retry@14672906e672a08bd6eeb15720e9ed3ce869cdd4 # v2
with:
timeout_minutes: 20
max_attempts: 3
Expand All @@ -80,7 +80,7 @@ jobs:
git config --local user.name "Selenium CI Bot"
git commit -m "Update tag in docs and files [skip ci]" -a
- name: Push changes
uses: ad-m/github-push-action@40bf560936a8022e68a3c00e7d2abefaf01305a6 # master
uses: ad-m/github-push-action@d91a481090679876dfc4178fef17f286781251df # master
with:
github_token: ${{ secrets.SELENIUM_CI_TOKEN }}
branch: trunk
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/helm-chart-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
permissions: write-all
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand All @@ -23,6 +23,6 @@ jobs:
git config user.email "[email protected]"
- name: Run chart-releaser
uses: helm/chart-releaser-action@v1.5.0
uses: helm/chart-releaser-action@v1.6.0
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
2 changes: 1 addition & 1 deletion .github/workflows/label-commenter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ jobs:
comment:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Label Commenter
uses: peaceiris/actions-label-commenter@v1
4 changes: 2 additions & 2 deletions .github/workflows/test-video.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ jobs:
name: Test video recorded through Docker Selenium
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Output Docker info
run: docker info
- name: Set up Python 3.8
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
python-version: 3.8
- name: Get branch name (only for push to branch)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-dev-beta-browser-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
CHANNEL: ${{ matrix.channel }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Setup environment variables
run: |
export SELENIUM_VERSION=$(grep selenium-server Base/Dockerfile | sed 's/.*-\([^-]*\)\.jar \\/\1/' | head -n 1)
Expand Down
8 changes: 4 additions & 4 deletions Base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ ENV DEBIAN_FRONTEND=noninteractive \
# Includes minimal runtime used for executing non GUI Java programs
#========================
RUN apt-get -qqy update \
&& apt-get upgrade -yq \
&& apt-get -qqy --no-install-recommends install \
acl \
bzip2 \
Expand Down Expand Up @@ -72,10 +73,8 @@ COPY supervisord.conf /etc
RUN mkdir -p /opt/selenium /opt/selenium/assets /var/run/supervisor /var/log/supervisor \
&& touch /opt/selenium/config.toml \
&& chmod -R 777 /opt/selenium /opt/selenium/assets /var/run/supervisor /var/log/supervisor /etc/passwd \
&& wget --no-verbose https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.11.0/selenium-server-4.11.0.jar \
&& wget --no-verbose https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.15.0/selenium-server-4.15.0.jar \
-O /opt/selenium/selenium-server.jar \
&& wget --no-verbose https://repo1.maven.org/maven2/org/seleniumhq/selenium/selenium-http-jdk-client/4.11.0/selenium-http-jdk-client-4.11.0.jar \
-O /opt/selenium/selenium-http-jdk-client.jar \
&& chgrp -R 0 /opt/selenium ${HOME} /opt/selenium/assets /var/run/supervisor /var/log/supervisor \
&& chmod -R g=u /opt/selenium ${HOME} /opt/selenium/assets /var/run/supervisor /var/log/supervisor \
&& setfacl -Rm u:seluser:rwx /opt /opt/selenium ${HOME} /opt/selenium/assets /var/run/supervisor /var/log/supervisor
Expand All @@ -89,9 +88,10 @@ RUN curl -fLo /tmp/cs https://github.com/coursier/launchers/raw/master/coursier
&& mkdir -p /external_jars \
&& chmod -R 775 /external_jars

RUN /tmp/cs fetch --classpath --cache /external_jars io.opentelemetry:opentelemetry-exporter-jaeger:1.26.0 io.grpc:grpc-netty:1.55.1 > /external_jars/.classpath.txt
RUN /tmp/cs fetch --classpath --cache /external_jars io.opentelemetry:opentelemetry-exporter-otlp:1.31.0 io.opentelemetry:opentelemetry-exporter-jaeger:1.31.0 io.grpc:grpc-netty:1.59.0 > /external_jars/.classpath.txt

RUN chmod 664 /external_jars/.classpath.txt
RUN rm -fr /root/.cache/*

#===================================================
# Run the following commands as non-privileged user
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ BUILD_ARGS := $(BUILD_ARGS)
MAJOR := $(word 1,$(subst ., ,$(TAG_VERSION)))
MINOR := $(word 2,$(subst ., ,$(TAG_VERSION)))
MAJOR_MINOR_PATCH := $(word 1,$(subst -, ,$(TAG_VERSION)))
FFMPEG_TAG_VERSION := $(or $(FFMPEG_TAG_VERSION),$(FFMPEG_TAG_VERSION),ffmpeg-4.3.1)
FFMPEG_TAG_VERSION := $(or $(FFMPEG_TAG_VERSION),$(FFMPEG_TAG_VERSION),ffmpeg-6.0)

all: hub \
distributor \
Expand Down Expand Up @@ -357,9 +357,9 @@ test_video: video hub chrome firefox edge
done
# Using ffmpeg to verify file integrity
# https://superuser.com/questions/100288/how-can-i-check-the-integrity-of-a-video-file-avi-mpeg-mp4
docker run -v $$(pwd):$$(pwd) -w $$(pwd) jrottenberg/ffmpeg:4.3.1-ubuntu2004 -v error -i ./tests/videos/chrome_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) jrottenberg/ffmpeg:4.3.1-ubuntu2004 -v error -i ./tests/videos/firefox_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) jrottenberg/ffmpeg:4.3.1-ubuntu2004 -v error -i ./tests/videos/edge_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) jrottenberg/ffmpeg:6.0-alpine -v error -i ./tests/videos/chrome_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) jrottenberg/ffmpeg:6.0-alpine -v error -i ./tests/videos/firefox_video.mp4 -f null - 2>error.log
docker run -v $$(pwd):$$(pwd) -w $$(pwd) jrottenberg/ffmpeg:6.0-alpine -v error -i ./tests/videos/edge_video.mp4 -f null - 2>error.log

.PHONY: \
all \
Expand Down
13 changes: 4 additions & 9 deletions NodeChrome/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,10 @@ USER 1200
ARG CHROME_DRIVER_VERSION
RUN if [ ! -z "$CHROME_DRIVER_VERSION" ]; \
then CHROME_DRIVER_URL=https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/$CHROME_DRIVER_VERSION/linux64/chromedriver-linux64.zip ; \
else echo "Geting ChromeDriver binary from https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions-with-downloads.json" \
&& CFT_URL=https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions-with-downloads.json \
&& CFT_CHANNEL="Stable" \
&& if [ "$CHROME_VERSION" = "google-chrome-beta" ]; then CFT_CHANNEL="Beta" ; fi \
&& if [ "$CHROME_VERSION" = "google-chrome-unstable" ]; then CFT_CHANNEL="Dev" ; fi \
&& echo $CFT_CHANNEL \
&& CTF_VALUES=$(curl -sSL $CFT_URL | jq -r --arg CFT_CHANNEL "$CFT_CHANNEL" '.channels[] | select (.channel==$CFT_CHANNEL)') \
&& CHROME_DRIVER_VERSION=$(echo $CTF_VALUES | jq -r '.version' ) \
&& CHROME_DRIVER_URL=$(echo $CTF_VALUES | jq -r '.downloads.chromedriver[] | select(.platform=="linux64") | .url' ) ; \
else echo "Geting ChromeDriver latest version from https://googlechromelabs.github.io/chrome-for-testing/LATEST_RELEASE_" \
&& CHROME_MAJOR_VERSION=$(google-chrome --version | sed -E "s/.* ([0-9]+)(\.[0-9]+){3}.*/\1/") \
&& CHROME_DRIVER_VERSION=$(wget -qO- https://googlechromelabs.github.io/chrome-for-testing/LATEST_RELEASE_${CHROME_MAJOR_VERSION} | sed 's/\r$//') \
&& CHROME_DRIVER_URL=https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/$CHROME_DRIVER_VERSION/linux64/chromedriver-linux64.zip ; \
fi \
&& echo "Using ChromeDriver from: "$CHROME_DRIVER_URL \
&& echo "Using ChromeDriver version: "$CHROME_DRIVER_VERSION \
Expand Down
8 changes: 4 additions & 4 deletions NodeDocker/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
# Configs have a mapping between the Docker image to use and the capabilities that need to be matched to
# start a container with the given image.
configs = [
"selenium/standalone-firefox:4.11.0-20230801", '{"browserName": "firefox", "platformName": "linux"}',
"selenium/standalone-chrome:4.11.0-20230801", '{"browserName": "chrome", "platformName": "linux"}',
"selenium/standalone-edge:4.11.0-20230801", '{"browserName": "MicrosoftEdge", "platformName": "linux"}'
"selenium/standalone-firefox:4.15.0-20231108", '{"browserName": "firefox", "platformName": "linux"}',
"selenium/standalone-chrome:4.15.0-20231108", '{"browserName": "chrome", "platformName": "linux"}',
"selenium/standalone-edge:4.15.0-20231108", '{"browserName": "MicrosoftEdge", "platformName": "linux"}'
]

# URL for connecting to the docker daemon
Expand All @@ -14,7 +14,7 @@ configs = [
# socat -4 TCP-LISTEN:2375,fork UNIX-CONNECT:/var/run/docker.sock
url = "http://127.0.0.1:2375"
# Docker image used for video recording
video-image = "selenium/video:ffmpeg-4.3.1-20230801"
video-image = "selenium/video:ffmpeg-6.0-20231108"

# Uncomment the following section if you are running the node on a separate VM
# Fill out the placeholders with appropriate values
Expand Down
Loading

0 comments on commit cc13ab1

Please sign in to comment.