Skip to content

Commit 26046d8

Browse files
authored
Merge branch 'SeleniumHQ:trunk' into chromium-cleanup
2 parents 94149c3 + a2aefd8 commit 26046d8

1,002 files changed

Lines changed: 19318 additions & 1082 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.ffmpeg/Dockerfile

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
FROM ubuntu:noble AS builder
2-
ARG FFMPEG_VERSION="8.0.1"
3-
ARG RCLONE_VER="v1.72.0"
2+
ARG FFMPEG_VERSION="8.1"
3+
ARG RCLONE_VER="v1.73-stable"
44
ARG GO_VERSION="latest"
55
#ARG GO_CRYPTO_VERSION="v0.36.0"
66
#ARG GO_OAUTH2_VERSION="v0.27.0"
@@ -33,9 +33,8 @@ RUN if [ "${GO_VERSION}" = "latest" ]; then \
3333
&& go version
3434

3535
RUN cd /usr/local/src \
36-
&& git clone https://github.com/rclone/rclone.git --filter=blob:none \
36+
&& git clone -b ${RCLONE_VER} --single-branch --depth 1 https://github.com/rclone/rclone.git \
3737
&& cd rclone \
38-
&& git checkout ${RCLONE_VER} \
3938
# Patch deps version in go.mod to fix CVEs
4039
# && sed -i "s|golang.org/x/crypto v.*|golang.org/x/crypto ${GO_CRYPTO_VERSION}|g" go.mod \
4140
# && sed -i "s|golang.org/x/oauth2 v.*|golang.org/x/oauth2 ${GO_OAUTH2_VERSION}|g" go.mod \
@@ -62,9 +61,8 @@ RUN cd /usr/local/src \
6261
# Install FFmpeg from source
6362
#======================================
6463
RUN cd /usr/local/src \
65-
&& git clone https://github.com/FFmpeg/FFmpeg.git --filter=blob:none \
64+
&& git clone -b release/${FFMPEG_VERSION} --single-branch --depth 1 https://github.com/FFmpeg/FFmpeg.git \
6665
&& cd FFmpeg \
67-
&& git checkout n${FFMPEG_VERSION} \
6866
&& rm -rf .git \
6967
&& PKG_CONFIG_PATH="/usr/local/lib/pkgconfig" FFMPEG_VERSION=${FFMPEG_VERSION} ./configure \
7068
--prefix="/usr/local" \

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ body:
5656
attributes:
5757
label: Docker Selenium version (image tag)
5858
description: What version of Docker Selenium are you using?
59-
placeholder: 4.39.0-20251212? Please use the full tag, avoid "latest"
59+
placeholder: 4.43.0-20260404? Please use the full tag, avoid "latest"
6060
validations:
6161
required: true
6262
- type: input

.github/actions/get-latest-upstream/action.yml

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,32 +6,51 @@ inputs:
66
required: false
77
type: boolean
88
default: false
9+
version:
10+
description: 'Specific Selenium version or release tag to use, e.g 4.42.1'
11+
required: false
12+
default: ''
913
gh_cli_token:
1014
description: 'GitHub CLI authentication token'
1115
required: true
1216
type: secret
17+
authors:
18+
description: 'GitHub organization or user to fetch Selenium releases from'
19+
required: false
20+
default: 'SeleniumHQ'
1321

1422
runs:
1523
using: "composite"
1624
steps:
1725
- name: Get latest upstream
1826
shell: bash
27+
env:
28+
AUTHORS: ${{ inputs.authors }}
29+
REQUESTED_VERSION: ${{ inputs.version }}
1930
run: |
2031
sudo apt update
2132
sudo apt install jq
2233
AUTH_HEADER="Authorization: token ${{ inputs.gh_cli_token }}"
23-
if [ "${{ inputs.release }}" = "true" ]; then
34+
RELEASES=$(curl -s -H "$AUTH_HEADER" https://api.github.com/repos/${AUTHORS}/selenium/releases)
35+
if [ -n "${REQUESTED_VERSION}" ]; then
36+
echo "Getting the requested Selenium release: ${REQUESTED_VERSION}"
37+
RELEASE=$(echo "${RELEASES}" | jq -r --arg requested "${REQUESTED_VERSION}" '[.[]? | select(.tag_name == $requested or .tag_name == ("selenium-" + $requested) or ([.assets[]?.name] | index("selenium-server-" + $requested + ".jar")))] | .[0].tag_name')
38+
if [ -z "${RELEASE}" ] || [ "${RELEASE}" = "null" ]; then
39+
echo "Requested Selenium release not found: ${REQUESTED_VERSION}"
40+
exit 1
41+
fi
42+
elif [ "${{ inputs.release }}" = "true" ]; then
2443
echo "Getting the latest stable release."
25-
RELEASE=$(curl -s -H "$AUTH_HEADER" https://api.github.com/repos/SeleniumHQ/selenium/releases | jq -r '[.[]? | select(.prerelease == false)] | .[0].tag_name')
44+
RELEASE=$(echo "${RELEASES}" | jq -r '[.[]? | select(.prerelease == false)] | .[0].tag_name')
2645
else
2746
echo "Getting the latest Nightly release."
28-
RELEASE=$(curl -s -H "$AUTH_HEADER" https://api.github.com/repos/SeleniumHQ/selenium/releases | jq -r '[.[]? | select(.prerelease == true)] | .[0].tag_name' || echo "")
47+
RELEASE=$(echo "${RELEASES}" | jq -r '[.[]? | select(.prerelease == true)] | .[0].tag_name' || echo "")
2948
if [ -z "${RELEASE}" ] || [ "${RELEASE}" = "null" ]; then
3049
echo "Nightly release not found, getting the latest stable release."
31-
RELEASE=$(curl -s -H "$AUTH_HEADER" https://api.github.com/repos/SeleniumHQ/selenium/releases | jq -r '[.[]? | select(.prerelease == false)] | .[0].tag_name')
50+
RELEASE=$(echo "${RELEASES}" | jq -r '[.[]? | select(.prerelease == false)] | .[0].tag_name')
3251
fi
3352
fi
34-
jar_file=$(curl -s -H "$AUTH_HEADER" https://api.github.com/repos/SeleniumHQ/selenium/releases/tags/${RELEASE} | jq -r '.assets[] | select(.name | endswith(".jar")) | .name' | tail -n 1)
53+
jar_file=$(curl -s -H "$AUTH_HEADER" https://api.github.com/repos/${AUTHORS}/selenium/releases/tags/${RELEASE} | jq -r '.assets[] | select(.name | endswith(".jar")) | .name' | tail -n 1)
3554
echo "Server package: ${jar_file}"
3655
VERSION=$(echo $jar_file | sed 's/selenium-server-//;s/\.jar//')
3756
echo "BASE_RELEASE=${RELEASE} | BASE_VERSION=${VERSION} | VERSION=${VERSION}"

.github/workflows/build-ffmpeg.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
cat .env | xargs -I {} echo {} >> $GITHUB_ENV
4646
env:
4747
NAMESPACE: ${{ vars.DOCKER_NAMESPACE || 'selenium' }}
48-
AUTHORS: ${{ vars.AUTHORS || 'SeleniumHQ' }}
48+
AUTHORS: ${{ vars.AUTHORS || github.repository_owner }}
4949
- name: Build images
5050
uses: nick-invision/retry@master
5151
with:
@@ -61,6 +61,9 @@ jobs:
6161
env:
6262
DOCKER_USERNAME: ${{secrets.DOCKER_USERNAME}}
6363
DOCKER_PASSWORD: ${{secrets.DOCKER_PASSWORD}}
64+
- name: Login GitHub Container Registry
65+
if: ${{ github.event.inputs.release == 'true' }}
66+
run: echo "${{ secrets.SELENIUM_CI_TOKEN }}" | docker login ghcr.io -u "${{ secrets.SELENIUM_CI_USERNAME }}" --password-stdin
6467
- name: Deploy new images
6568
if: ${{ github.event.inputs.release == 'true' }}
6669
uses: nick-invision/retry@master
@@ -70,3 +73,12 @@ jobs:
7073
retry_wait_seconds: 300
7174
command: |
7275
make release_ffmpeg_latest
76+
- name: Mirror images to GHCR
77+
if: ${{ github.event.inputs.release == 'true' }}
78+
uses: nick-invision/retry@master
79+
with:
80+
timeout_minutes: 20
81+
max_attempts: 5
82+
retry_wait_seconds: 300
83+
command: |
84+
GHCR_NAMESPACE="ghcr.io/$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]')" make release_ffmpeg_ghcr_latest

.github/workflows/create-changelog-pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
- name: Create CHANGELOG directory
4545
run: mkdir -p ./CHANGELOG/${{ inputs.grid-version }}
4646
- name: Download results
47-
uses: actions/download-artifact@v7
47+
uses: actions/download-artifact@v8
4848
with:
4949
path: ./CHANGELOG/${{ inputs.grid-version }}
5050
pattern: 'image_tags_*'

.github/workflows/deploy.yml

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ on:
88
required: true
99
type: string
1010
default: 'true'
11+
version:
12+
description: 'Specific Selenium version or release tag to use, e.g 4.42.1'
13+
required: false
14+
default: ''
1115
release:
1216
description: 'Deploy a new release'
1317
required: false
@@ -82,7 +86,9 @@ jobs:
8286
uses: ./.github/actions/get-latest-upstream
8387
with:
8488
release: ${{ github.event.inputs.stable || true }}
89+
version: ${{ github.event.inputs.version || '' }}
8590
gh_cli_token: ${{ secrets.GITHUB_TOKEN }}
91+
authors: ${{ vars.AUTHORS || github.repository_owner }}
8692
- name: Sets build date
8793
run: |
8894
if [ -z "${BUILD_DATE}" ]; then
@@ -95,7 +101,7 @@ jobs:
95101
cat .env | xargs -I {} echo {} >> $GITHUB_ENV
96102
env:
97103
NAMESPACE: ${{ vars.DOCKER_NAMESPACE || 'selenium' }}
98-
AUTHORS: ${{ vars.AUTHORS || 'SeleniumHQ' }}
104+
AUTHORS: ${{ vars.AUTHORS || github.repository_owner }}
99105
BUILD_DATE: ${{ github.event.inputs.build-date || '' }}
100106
- name: Sets prerelease to false by default
101107
run: echo "PRERELEASE=false" >> $GITHUB_ENV
@@ -145,6 +151,9 @@ jobs:
145151
env:
146152
DOCKER_USERNAME: ${{secrets.DOCKER_USERNAME}}
147153
DOCKER_PASSWORD: ${{secrets.DOCKER_PASSWORD}}
154+
- name: Login GitHub Container Registry
155+
if: github.event.inputs.skip-build-push-image != 'true'
156+
run: echo "${{ secrets.SELENIUM_CI_TOKEN }}" | docker login ghcr.io -u "${{ secrets.SELENIUM_CI_USERNAME }}" --password-stdin
148157
- name: Deploy new images
149158
if: github.event.inputs.skip-build-push-image != 'true'
150159
uses: nick-invision/retry@master
@@ -153,6 +162,14 @@ jobs:
153162
max_attempts: 5
154163
retry_wait_seconds: 300
155164
command: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make release
165+
- name: Mirror versioned images to GHCR
166+
if: github.event.inputs.skip-build-push-image != 'true'
167+
uses: nick-invision/retry@master
168+
with:
169+
timeout_minutes: 30
170+
max_attempts: 5
171+
retry_wait_seconds: 300
172+
command: GHCR_NAMESPACE="ghcr.io/$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]')" VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make release_ghcr
156173
- name: Tag images as latest
157174
if: github.event.inputs.skip-build-push-image != 'true'
158175
run: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make tag_latest
@@ -164,6 +181,14 @@ jobs:
164181
max_attempts: 5
165182
retry_wait_seconds: 300
166183
command: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make release_latest
184+
- name: Mirror latest images to GHCR
185+
if: github.event.inputs.skip-build-push-image != 'true'
186+
uses: nick-invision/retry@master
187+
with:
188+
timeout_minutes: 20
189+
max_attempts: 5
190+
retry_wait_seconds: 300
191+
command: GHCR_NAMESPACE="ghcr.io/$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]')" VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make release_ghcr_latest
167192
- name: Update package versions
168193
run: make update_browser_versions_matrix
169194
# make generate_latest_sbom
@@ -176,6 +201,14 @@ jobs:
176201
max_attempts: 5
177202
retry_wait_seconds: 300
178203
command: VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} PUSH_IMAGE=true make tag_and_push_browser_images
204+
- name: Mirror browser images to GHCR
205+
if: github.event.inputs.skip-build-push-image != 'true'
206+
uses: nick-invision/retry@master
207+
with:
208+
timeout_minutes: 30
209+
max_attempts: 5
210+
retry_wait_seconds: 300
211+
command: GHCR_NAMESPACE="ghcr.io/$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]')" VERSION="${GRID_VERSION}" BUILD_DATE=${BUILD_DATE} make tag_and_push_browser_images_ghcr
179212
- name: Delete previous nightly tag & release if any
180213
uses: dev-drprasad/delete-tag-and-release@master
181214
with:
@@ -208,7 +241,7 @@ jobs:
208241
- name: Create Release
209242
if: env.LATEST_TAG != env.NEXT_TAG
210243
id: create_release
211-
uses: softprops/action-gh-release@v2.5.0
244+
uses: softprops/action-gh-release@v3.0.0
212245
with:
213246
token: ${{ secrets.GITHUB_TOKEN }}
214247
tag_name: "${{ env.GRID_VERSION }}-${{ env.BUILD_DATE }}"

.github/workflows/docker-test.yml

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,34 +55,39 @@ jobs:
5555
os: ubuntu-24.04
5656
firefox-install-lang-package:
5757
enable-managed-downloads:
58+
retain-on-failure:
5859
- test-strategy: test_video_dynamic_name
5960
use-random-user: false
6061
test-video: true
6162
build-all: false
6263
os: ubuntu-24.04
6364
firefox-install-lang-package:
6465
enable-managed-downloads:
66+
retain-on-failure:
6567
- test-strategy: test_video_standalone
6668
use-random-user: false
6769
test-video: true
6870
build-all: false
6971
os: ubuntu-24.04
7072
firefox-install-lang-package:
7173
enable-managed-downloads:
74+
retain-on-failure:
7275
- test-strategy: test_node_docker
7376
use-random-user: false
7477
test-video: true
7578
build-all: false
7679
os: ubuntu-24.04
7780
firefox-install-lang-package:
7881
enable-managed-downloads:
82+
retain-on-failure:
7983
- test-strategy: test_standalone_docker
8084
use-random-user: false
8185
test-video: true
8286
build-all: false
8387
os: ubuntu-24.04
8488
firefox-install-lang-package:
8589
enable-managed-downloads:
90+
retain-on-failure:
8691
- test-strategy: test_parallel
8792
use-random-user: false
8893
test-video: false
@@ -119,34 +124,39 @@ jobs:
119124
os: ubuntu-24.04-arm
120125
firefox-install-lang-package: true
121126
enable-managed-downloads: true
127+
retain-on-failure: true
122128
- test-strategy: test_video_dynamic_name
123129
use-random-user: false
124130
test-video: true
125131
build-all: false
126132
os: ubuntu-24.04-arm
127133
firefox-install-lang-package: true
128134
enable-managed-downloads: true
135+
retain-on-failure: true
129136
- test-strategy: test_video_standalone
130137
use-random-user: false
131138
test-video: true
132139
build-all: false
133140
os: ubuntu-24.04-arm
134141
firefox-install-lang-package: true
135142
enable-managed-downloads: true
136-
- test-strategy: test_node_docker
143+
retain-on-failure: true
144+
- test-strategy: test_node_docker_video_sidecar
137145
use-random-user: false
138146
test-video: true
139147
build-all: false
140148
os: ubuntu-24.04-arm
141149
firefox-install-lang-package: true
142150
enable-managed-downloads: false
143-
- test-strategy: test_standalone_docker
151+
retain-on-failure: true
152+
- test-strategy: test_standalone_docker_video_sidecar
144153
use-random-user: false
145154
test-video: true
146155
build-all: false
147156
os: ubuntu-24.04-arm
148157
firefox-install-lang-package: true
149158
enable-managed-downloads: true
159+
retain-on-failure: true
150160
- test-strategy: test_parallel
151161
use-random-user: false
152162
test-video: false
@@ -212,12 +222,13 @@ jobs:
212222
with:
213223
release: ${{ inputs.release || false }}
214224
gh_cli_token: ${{ secrets.GITHUB_TOKEN }}
225+
authors: ${{ vars.AUTHORS || github.repository_owner }}
215226
- name: Sets build date
216227
run: |
217228
echo "BUILD_DATE=$(date '+%Y%m%d')" >> $GITHUB_ENV
218229
echo "AUTHORS=${AUTHORS}" >> $GITHUB_ENV
219230
env:
220-
AUTHORS: ${{ vars.AUTHORS || 'SeleniumHQ' }}
231+
AUTHORS: ${{ vars.AUTHORS || github.repository_owner }}
221232
- name: Build Docker images
222233
uses: nick-invision/retry@master
223234
if: matrix.build-all == true
@@ -245,9 +256,13 @@ jobs:
245256
if [ -n "${SELENIUM_ENABLE_MANAGED_DOWNLOADS}" ]; then
246257
echo "SELENIUM_ENABLE_MANAGED_DOWNLOADS=${SELENIUM_ENABLE_MANAGED_DOWNLOADS}" >> $GITHUB_ENV
247258
fi
259+
if [ -n "${TEST_RETAIN_ON_FAILURE}" ]; then
260+
echo "TEST_RETAIN_ON_FAILURE=${TEST_RETAIN_ON_FAILURE}" >> $GITHUB_ENV
261+
fi
248262
env:
249263
TEST_FIREFOX_INSTALL_LANG_PACKAGE: ${{ matrix.firefox-install-lang-package }}
250264
SELENIUM_ENABLE_MANAGED_DOWNLOADS: ${{ matrix.enable-managed-downloads }}
265+
TEST_RETAIN_ON_FAILURE: ${{ matrix.retain-on-failure }}
251266
- name: Run Docker Compose to ${{ matrix.test-strategy }} on AMD64
252267
if: contains(matrix.os, 'arm') == false
253268
uses: nick-invision/retry@master
@@ -267,6 +282,7 @@ jobs:
267282
command: |
268283
USE_RANDOM_USER_ID=${{ matrix.use-random-user }} VERSION=${BRANCH} BUILD_DATE=${BUILD_DATE} \
269284
TEST_FIREFOX_INSTALL_LANG_PACKAGE=${TEST_FIREFOX_INSTALL_LANG_PACKAGE} SELENIUM_ENABLE_MANAGED_DOWNLOADS=${SELENIUM_ENABLE_MANAGED_DOWNLOADS} \
285+
TEST_RETAIN_ON_FAILURE=${TEST_RETAIN_ON_FAILURE} \
270286
make ${{ matrix.test-strategy }}
271287
- name: Upload recorded video
272288
if: matrix.test-video == true

.github/workflows/helm-chart-test.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,12 +181,13 @@ jobs:
181181
with:
182182
release: ${{ inputs.release || false }}
183183
gh_cli_token: ${{ secrets.GITHUB_TOKEN }}
184+
authors: ${{ vars.AUTHORS || github.repository_owner }}
184185
- name: Sets build date
185186
run: |
186187
echo "BUILD_DATE=$(date '+%Y%m%d')" >> $GITHUB_ENV
187188
echo "AUTHORS=${AUTHORS}" >> $GITHUB_ENV
188189
env:
189-
AUTHORS: ${{ vars.AUTHORS || 'SeleniumHQ' }}
190+
AUTHORS: ${{ vars.AUTHORS || github.repository_owner }}
190191
- name: Build Helm charts
191192
run: |
192193
BUILD_DATE=${BUILD_DATE} make chart_build

0 commit comments

Comments
 (0)