Skip to content

Commit

Permalink
Merge branch 'master' into fixcleaner-dup-tags
Browse files Browse the repository at this point in the history
  • Loading branch information
lemeurherve authored Oct 29, 2023
2 parents 8b4df89 + 3c099dd commit 2885e75
Show file tree
Hide file tree
Showing 15 changed files with 104 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ jobs:
runs-on: ubuntu-latest
steps:
# Drafts your next Release notes as Pull Requests are merged into the default branch
- uses: release-drafter/release-drafter@v5.24.0
- uses: release-drafter/release-drafter@v5.25.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/updatecli.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
uses: actions/checkout@v4

- name: Install Updatecli in the runner
uses: updatecli/updatecli-action@v2.44.0
uses: updatecli/updatecli-action@v2.46.1

- name: Run Updatecli in Dry Run mode
run: updatecli diff --config ./updatecli/updatecli.d --values ./updatecli/values.github-action.yaml
Expand Down
2 changes: 1 addition & 1 deletion alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ RUN apk add --no-cache \
tzdata-utils \
&& rm -rf /tmp/*.apk /tmp/gcc /tmp/gcc-libs.tar* /tmp/libz /tmp/libz.tar.xz /var/cache/apk/*

ARG VERSION=3180.v3dd999d24861
ARG VERSION=3186.vc3b_7249b_87eb_
ADD --chown="${user}":"${group}" "https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/${VERSION}/remoting-${VERSION}.jar" /usr/share/jenkins/agent.jar
RUN chmod 0644 /usr/share/jenkins/agent.jar \
&& ln -sf /usr/share/jenkins/agent.jar /usr/share/jenkins/slave.jar
Expand Down
4 changes: 2 additions & 2 deletions archlinux/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ RUN jlink \
--compress=2 \
--output /javaruntime

FROM archlinux:base-20231001.0.182270
FROM archlinux:base-20231015.0.185077

ARG user=jenkins
ARG group=jenkins
Expand All @@ -49,7 +49,7 @@ ENV TZ=Etc/UTC

RUN pacman -Syu curl git git-lfs openssh tzdata --noconfirm

ARG VERSION=3180.v3dd999d24861
ARG VERSION=3186.vc3b_7249b_87eb_
ADD --chown="${user}":"${group}" "https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/${VERSION}/remoting-${VERSION}.jar" /usr/share/jenkins/agent.jar
RUN chmod 0644 /usr/share/jenkins/agent.jar \
&& ln -sf /usr/share/jenkins/agent.jar /usr/share/jenkins/slave.jar
Expand Down
2 changes: 1 addition & 1 deletion build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Param(
[Parameter(Position=1)]
[String] $Target = "build",
[String] $Build = '',
[String] $RemotingVersion = '3180.v3dd999d24861',
[String] $RemotingVersion = '3186.vc3b_7249b_87eb_',
[String] $BuildNumber = '1',
[switch] $PushVersions = $false,
[switch] $DisableEnvProps = $false,
Expand Down
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ OPTIND=1

target="build"
build_number="1"
remoting_version="3180.v3dd999d24861"
remoting_version="3186.vc3b_7249b_87eb_"
disable_env_props=0
exit_result=0

Expand Down
2 changes: 1 addition & 1 deletion debian/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ RUN apt-get update \
&& apt-get clean \
&& rm -rf /tmp/* /var/cache/* /var/lib/apt/lists/*

ARG VERSION=3180.v3dd999d24861
ARG VERSION=3186.vc3b_7249b_87eb_
ADD --chown="${user}":"${group}" "https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/${VERSION}/remoting-${VERSION}.jar" /usr/share/jenkins/agent.jar
RUN chmod 0644 /usr/share/jenkins/agent.jar \
&& ln -sf /usr/share/jenkins/agent.jar /usr/share/jenkins/slave.jar
Expand Down
6 changes: 3 additions & 3 deletions debian/preview/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ARG TARGETPLATFORM
SHELL ["/bin/bash", "-o", "pipefail", "-c"]

## Example of preview (EA) jdk21 JAVA_VERSION values:
# 21+35 (special case)
# 21+35 (note: only one number before the "+")
# 21.0.1+12
## Example of preview (EA) release download link:
# https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21%2B35-ea-beta/OpenJDK21U-jdk_x64_linux_hotspot_ea_21-0-35.tar.gz
Expand All @@ -18,8 +18,8 @@ RUN set -x; apt-get update \
ca-certificates \
jq \
wget \
&& DASHED_JAVA_VERSION=$(echo "${JAVA_VERSION}" | sed -e 's/\./-/g' -e 's/+/-/' -e 's/21-35/21-0-35/') \
&& JAVA_MAJOR_VERSION=$(echo $JAVA_VERSION | cut -d'+' -f1) \
&& DASHED_JAVA_VERSION=$(echo "$JAVA_VERSION" | sed -e 's/\./-/g' -e 's/+/-/' -e 's/21-35/21-0-35/') \
&& JAVA_MAJOR_VERSION=$(echo "$JAVA_VERSION" | cut -d'+' -f1 | cut -d'.' -f1) \
&& ENCODED_JAVA_VERSION=$(echo "$JAVA_VERSION" | jq "@uri" -jRr) \
&& CONVERTED_ARCH=$(arch | sed -e 's/x86_64/x64/' -e 's/armv7l/arm/') \
&& wget --quiet https://github.com/adoptium/temurin"${JAVA_MAJOR_VERSION}"-binaries/releases/download/jdk-"${ENCODED_JAVA_VERSION}"-ea-beta/OpenJDK"${JAVA_MAJOR_VERSION}"U-jdk_"${CONVERTED_ARCH}"_linux_hotspot_ea_"${DASHED_JAVA_VERSION}".tar.gz -O /tmp/jdk.tar.gz \
Expand Down
4 changes: 2 additions & 2 deletions docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ group "linux-ppc64le" {
}

variable "REMOTING_VERSION" {
default = "3180.v3dd999d24861"
default = "3186.vc3b_7249b_87eb_"
}

variable "REGISTRY" {
Expand Down Expand Up @@ -88,7 +88,7 @@ variable "JAVA21_VERSION" {
}

variable "JAVA21_PREVIEW_VERSION" {
default = "21+35"
default = "21.0.1+12"
}

target "archlinux_jdk11" {
Expand Down
2 changes: 1 addition & 1 deletion env.props
Original file line number Diff line number Diff line change
@@ -1 +1 @@
REMOTING_VERSION=3180.v3dd999d24861
REMOTING_VERSION=3186.vc3b_7249b_87eb_
19 changes: 14 additions & 5 deletions updatecli/scripts/check-jdk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,18 @@ function get_jdk_download_url() {
## JDK19 URLs have an underscore ('_') instead of a plus ('+') in their archive names
echo "https://github.com/adoptium/temurin19-binaries/releases/download/jdk-${jdk_version}/OpenJDK19U-jdk_${platform}_hotspot_${jdk_version//+/_}";
return 0;;
21*)
# JDK version (21+35-ea-beta)
21*-ea-beta)
# JDK preview version (21+35-ea-beta, 21.0.1+12-ea-beta)
jdk_version="${jdk_version//-ea-beta}"
## https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21%2B35-ea-beta/OpenJDK21U-jdk_aarch64_linux_hotspot_ea_21-0-35.tar.gz
urlEncodedJDKVersion="${jdk_version//+/%2B}"
echo "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-${urlEncodedJDKVersion}-ea-beta/OpenJDK21U-jdk_${platform}_hotspot_ea_21-0-$(echo ${jdk_version} | cut -d '+' -f 2 | cut -d '-' -f 1)"
## https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.1%2B12-ea-beta/OpenJDK21U-jdk_x64_linux_hotspot_ea_21-0-1-12.tar.gz
dashJDKVersion="${jdk_version//+/-}"
completeDashJDKVersion="${dashJDKVersion//./-}"
echo "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-${jdk_version//+/%2B}-ea-beta/OpenJDK21U-jdk_${platform}_hotspot_ea_${completeDashJDKVersion}"
return 0;;
21*)
## JDK21 URLs have an underscore ('_') instead of a plus ('+') in their archive names
echo "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-${jdk_version}/OpenJDK21U-jdk_${platform}_hotspot_${jdk_version//+/_}";
return 0;;
*)
echo "ERROR: unsupported JDK version (${jdk_version}).";
Expand All @@ -51,8 +58,10 @@ case "${1}" in
platforms=("x64_linux" "x64_windows" "aarch64_linux" "s390x_linux");;
19.*+*)
platforms=("x64_linux" "x64_windows" "aarch64_linux" "s390x_linux");;
21*+*)
21*+*-ea-beta)
platforms=("x64_linux" "x64_windows" "aarch64_linux" "s390x_linux");;
21*+*)
platforms=("x64_linux" "x64_windows" "aarch64_linux");;
*)
echo "ERROR: unsupported JDK version (${1}).";
exit 1;;
Expand Down
63 changes: 63 additions & 0 deletions updatecli/updatecli.d/jdk21-preview.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
---
name: Bump JDK21 preview version (EA) for all Linux images

scms:
default:
kind: github
spec:
user: "{{ .github.user }}"
email: "{{ .github.email }}"
owner: "{{ .github.owner }}"
repository: "{{ .github.repository }}"
token: "{{ requiredEnv .github.token }}"
username: "{{ .github.username }}"
branch: "{{ .github.branch }}"
temurin21-binaries:
kind: "github"
spec:
user: "{{ .github.user }}"
email: "{{ .github.email }}"
owner: "adoptium"
repository: "temurin21-binaries"
token: '{{ requiredEnv .github.token }}'
branch: "main"

sources:
getLatestJDK21PreviewVersion:
name: Get the latest Adoptium preview (EA) JDK21 version
kind: gittag
scmid: temurin21-binaries
spec:
versionfilter:
kind: regex
pattern: ".*-ea-.*"
transformers:
- trimprefix: "jdk-"
- trimsuffix: "-ea-beta"

conditions:
checkIfReleaseIsAvailable:
kind: shell
spec:
command: bash ./updatecli/scripts/check-jdk.sh # source input value passed as argument
transformers:
- addsuffix: "-ea-beta"

targets:
setJDK21PreviewVersionDockerBake:
name: "Bump preview (EA) JDK21 version for Linux images in the docker-bake.hcl file"
kind: hcl
spec:
file: docker-bake.hcl
path: variable.JAVA21_PREVIEW_VERSION.default
scmid: default

actions:
default:
kind: github/pullrequest
scmid: default
title: Bump preview (EA) JDK21 version to {{ source "getLatestJDK21PreviewVersion" }}
spec:
labels:
- dependencies
- jdk21-preview
15 changes: 11 additions & 4 deletions updatecli/updatecli.d/jdk21.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,29 @@ scms:
branch: "main"

sources:
getLatestJDK21EAVersion:
getLatestJDK21Version:
name: Get the latest Adoptium JDK21 version
kind: gittag
scmid: temurin21-binaries
spec:
versionfilter:
kind: regex
pattern: ".*-ea-.*"
pattern: "\\d$"
transformers:
- trimprefix: "jdk-"
- trimsuffix: "-ea-beta"
- replacer:
from: "+"
to: "_"

conditions:
checkIfReleaseIsAvailable:
kind: shell
spec:
command: bash ./updatecli/scripts/check-jdk.sh # source input value passed as argument
transformers:
- replacer:
from: "_"
to: "+"

targets:
setJDK21Version:
Expand All @@ -54,7 +60,8 @@ actions:
default:
kind: github/pullrequest
scmid: default
title: Bump JDK21 version to {{ source "getLatestJDK21EAVersion" }}
title: Bump JDK21 version to {{ source "getLatestJDK21Version" }}
spec:
labels:
- dependencies
- jdk21
2 changes: 1 addition & 1 deletion windows/nanoserver/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ ARG AGENT_WORKDIR=${AGENT_ROOT}/Work
ENV AGENT_WORKDIR=${AGENT_WORKDIR}

# Get the Agent from the Jenkins Artifacts Repository
ARG VERSION=3180.v3dd999d24861
ARG VERSION=3186.vc3b_7249b_87eb_
RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 ; `
Invoke-WebRequest $('https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/{0}/remoting-{0}.jar' -f $env:VERSION) -OutFile $(Join-Path C:/ProgramData/Jenkins $env:AGENT_FILENAME) -UseBasicParsing ; `
Invoke-WebRequest $('https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/{0}/remoting-{0}.jar.sha1' -f $env:VERSION) -OutFile (Join-Path C:/ProgramData/Jenkins $env:AGENT_HASH_FILENAME) -UseBasicParsing ; `
Expand Down
2 changes: 1 addition & 1 deletion windows/windowsservercore/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ ARG AGENT_WORKDIR=${AGENT_ROOT}/Work
ENV AGENT_WORKDIR=${AGENT_WORKDIR}

# Get the Agent from the Jenkins Artifacts Repository
ARG VERSION=3180.v3dd999d24861
ARG VERSION=3186.vc3b_7249b_87eb_
RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 ; `
Invoke-WebRequest $('https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/{0}/remoting-{0}.jar' -f $env:VERSION) -OutFile $(Join-Path C:/ProgramData/Jenkins $env:AGENT_FILENAME) -UseBasicParsing ; `
Invoke-WebRequest $('https://repo.jenkins-ci.org/public/org/jenkins-ci/main/remoting/{0}/remoting-{0}.jar.sha1' -f $env:VERSION) -OutFile (Join-Path C:/ProgramData/Jenkins $env:AGENT_HASH_FILENAME) -UseBasicParsing ; `
Expand Down

0 comments on commit 2885e75

Please sign in to comment.