From c5d59ea16ffe83a7b738a48ed90d058be82cdb09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Le=20Meur?= Date: Tue, 7 Jul 2026 19:29:13 +0200 Subject: [PATCH 1/6] cleanup(pipeline): remove unused `SIMULATE_LTS_BUILD` --- Jenkinsfile | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index f2bdbfbca2..1e71dbdfd5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -24,23 +24,6 @@ def architecturesAndCiJioAgentLabels = [ 's390x': 'docker && amd64', ] -// Set to true in a replay to simulate a LTS build on ci.jenkins.io -// It will set the environment variables needed for a LTS -// and disable images publication out of caution -def SIMULATE_LTS_BUILD = false - -if (SIMULATE_LTS_BUILD) { - envVars = [ - 'PUBLISH=false', - 'TAG_NAME=2.504.3', - // TODO: replace by the first LTS based on 2.534+ when available - 'JENKINS_VERSION=2.555.1', - // Filter out golden file based testing - // To filter out all tests, set BATS_FLAGS="--filter-tags none" - 'BATS_FLAGS=--filter-tags "\\!test-type:golden-file"' - ] -} - stage('Build') { def builds = [:] From 0ed66cbeb6389f819e0e77c41ce2baffc808c83a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Le=20Meur?= Date: Tue, 7 Jul 2026 19:29:50 +0200 Subject: [PATCH 2/6] cleanup(pipeline): remove incorrect and unhelpful `echo` --- Jenkinsfile | 2 -- 1 file changed, 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 1e71dbdfd5..f71d977655 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -28,8 +28,6 @@ stage('Build') { def builds = [:] withEnv(envVars) { - echo '= bake target: linux' - def windowsImageTypes = [ 'windowsservercore-ltsc2022', 'windowsservercore-ltsc2025', From ce2db70443b205a4c1c3474288e97b0e2cbab4b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Le=20Meur?= Date: Tue, 7 Jul 2026 19:34:31 +0200 Subject: [PATCH 3/6] chore(pipeline): remove commented out experimental publication stage --- Jenkinsfile | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index f71d977655..d812b30405 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,7 @@ H 6,21 * * 3''')]) properties(listOfProperties) -// Default environment variable set to allow images publication +// Default environment variable set to allow images publication from trusted.ci.jenkins.io def envVars = ['PUBLISH=true'] // List of architectures and corresponding ci.jenkins.io agent labels @@ -79,18 +79,6 @@ stage('Build') { error('Windows test stage failed.') } } - - // disable until we get the parallel changes merged in - // def branchName = "${env.BRANCH_NAME}" - // if (branchName ==~ 'master'){ - // stage('Publish Experimental') { - // infra.withDockerCredentials { - // withEnv(['DOCKERHUB_ORGANISATION=jenkins4eval','DOCKERHUB_REPO=jenkins']) { - // powershell './make.ps1 publish' - // } - // } - // } - // } } else { // Only publish when a tag triggered the build & the publication is enabled (ie not simulating a LTS) if (env.TAG_NAME && (env.PUBLISH == 'true')) { From bfff454023411a6a8622d6b1320654094cec6c2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Le=20Meur?= Date: Tue, 7 Jul 2026 19:46:00 +0200 Subject: [PATCH 4/6] chore(pipeline): regroup list of what is built on top of the pipeline for easier replays --- Jenkinsfile | 38 +++++++++++++++++++++----------------- 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index d812b30405..cc4a90c6de 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,7 +14,8 @@ properties(listOfProperties) // Default environment variable set to allow images publication from trusted.ci.jenkins.io def envVars = ['PUBLISH=true'] -// List of architectures and corresponding ci.jenkins.io agent labels +// List of dedicated architecture Linux builds and corresponding ci.jenkins.io agent labels +// Note: not taken in account on trusted.ci.jenkins.io as Linux builds are multiarch there def architecturesAndCiJioAgentLabels = [ 'amd64': 'docker && amd64', 'arm64': 'arm64docker', @@ -23,15 +24,29 @@ def architecturesAndCiJioAgentLabels = [ 'riscv64': 'docker && amd64', 's390x': 'docker && amd64', ] +// List of Windows image types to build on ci.jenkins.io and trusted.ci.jenkins.io +def windowsImageTypes = [ + 'windowsservercore-ltsc2022', + 'windowsservercore-ltsc2025', +] +// List of Linux targets to build on ci.jenkins.io +// An up to date list can be obtained with make list-linux +// Note: on trusted.ci.jenkins.io, the 'linux' target is used instead +def images = [ + 'alpine_jdk21', + 'alpine_jdk25', + 'debian_jdk21', + 'debian_jdk25', + 'debian-slim_jdk21', + 'debian-slim_jdk25', + 'rhel_jdk21', + 'rhel_jdk25', +] stage('Build') { def builds = [:] withEnv(envVars) { - def windowsImageTypes = [ - 'windowsservercore-ltsc2022', - 'windowsservercore-ltsc2025', - ] for (anImageType in windowsImageTypes) { def imageType = anImageType builds[imageType] = { @@ -117,19 +132,8 @@ stage('Build') { } if (!infra.isTrusted()) { - // An up to date list can be obtained with make list-linux - def images = [ - 'alpine_jdk21', - 'alpine_jdk25', - 'debian_jdk21', - 'debian_jdk25', - 'debian-slim_jdk21', - 'debian-slim_jdk25', - 'rhel_jdk21', - 'rhel_jdk25', - ] for (i in images) { - def imageToBuild = i + def imageToBuild = t builds[imageToBuild] = { nodeWithTimeout(architecturesAndCiJioAgentLabels["amd64"]) { From 6c89e8db09efa835f7ffedc71b569b646a1802bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Le=20Meur?= Date: Tue, 7 Jul 2026 20:08:24 +0200 Subject: [PATCH 5/6] chore(pipeline): rename `images` list to `linuxTargets` --- Jenkinsfile | 16 ++++++++-------- tests/test_helpers.bash | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index cc4a90c6de..ca51fe0e70 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -32,7 +32,7 @@ def windowsImageTypes = [ // List of Linux targets to build on ci.jenkins.io // An up to date list can be obtained with make list-linux // Note: on trusted.ci.jenkins.io, the 'linux' target is used instead -def images = [ +def linuxTargets = [ 'alpine_jdk21', 'alpine_jdk25', 'debian_jdk21', @@ -132,10 +132,10 @@ stage('Build') { } if (!infra.isTrusted()) { - for (i in images) { - def imageToBuild = t + for (t in linuxTargets) { + def targetToBuild = t - builds[imageToBuild] = { + builds[targetToBuild] = { nodeWithTimeout(architecturesAndCiJioAgentLabels["amd64"]) { deleteDir() @@ -150,15 +150,15 @@ stage('Build') { /* Outside of the trusted.ci environment, we're building and testing * the Dockerfile in this repository, but not publishing to docker hub */ - stage("Build linux-${imageToBuild}") { - sh "make build-${imageToBuild}" + stage("Build linux-${targetToBuild}") { + sh "make build-${targetToBuild}" archiveArtifacts artifacts: 'target/build-result-metadata_*.json', allowEmptyArchive: true } - stage("Test linux-${imageToBuild}") { + stage("Test linux-${targetToBuild}") { sh 'make prepare-test' try { - sh "make test-${imageToBuild}" + sh "make test-${targetToBuild}" } catch (err) { error("${err.toString()}") } finally { diff --git a/tests/test_helpers.bash b/tests/test_helpers.bash index 70bcd457f7..6343e44033 100644 --- a/tests/test_helpers.bash +++ b/tests/test_helpers.bash @@ -116,7 +116,7 @@ function get_jenkins_password { } function get_targets_from_jenkinsfile { - sed -n '/def images = \[/,/]/p' Jenkinsfile `# retrieve images array from Jenkinsfile` \ + sed -n '/def linuxTargets = \[/,/]/p' Jenkinsfile `# retrieve linuxTargets array from Jenkinsfile` \ | grep "'" `# keep only its items` \ | tr -d "', " `# cleanup output` \ | sort `# ensure constant output sort` From e8c716f9c231cb1247ace921cee2f68c372ae2bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Jare=C5=A1?= Date: Wed, 8 Jul 2026 09:59:13 +0200 Subject: [PATCH 6/6] Also fail on Pester block/container failures (not just failed tests) (#2390) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Also fail on Pester block/container failures, not just failed tests In Pester 5 a run has three independent failure counts. Gating only on FailedCount misses FailedBlocksCount (BeforeAll/AfterAll) and FailedContainersCount (files that fail to discover/load), so a failing BeforeAll or an unloadable test file passes the build green. This adds those counts to the gate. Generated with AI (GitHub Copilot CLI). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Update make.ps1 Co-authored-by: Hervé Le Meur <91831478+lemeurherve@users.noreply.github.com> * delimit var name --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: Mark Waite Co-authored-by: Hervé Le Meur <91831478+lemeurherve@users.noreply.github.com> --- make.ps1 | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/make.ps1 b/make.ps1 index e25adcea81..855303f0a0 100644 --- a/make.ps1 +++ b/make.ps1 @@ -94,8 +94,11 @@ function Test-Image { $TestResults = Invoke-Pester -Configuration $configuration $failed = $false - if ($TestResults.FailedCount -gt 0) { - Write-Host "There were $($TestResults.FailedCount) failed tests in $tag" + if (($TestResults.FailedCount + $TestResults.FailedBlocksCount + $TestResults.FailedContainersCount) -gt 0) { + Write-Host "Failure(s) in ${tag}:" + Write-Host "- $TestResults.FailedCount failed test(s)" + Write-Host "- $TestResults.FailedBlocksCount failed BeforeAll/AfterAll block(s)" + Write-Host "- $TestResults.FailedContainersCount file(s) that errored during discovery or failed to load" $failed = $true } else { Write-Host "There were $($TestResults.PassedCount) passed tests out of $($TestResults.TotalCount) in $tag"