From d2372e4679f0c3b8e86099dc6a12b7086a5e6f3f Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:48:44 +0200 Subject: [PATCH 1/7] Configure a mirror for registry-image image_resources --- ci/parameters.yml | 5 ++++- ci/pipeline.yml | 9 +++++++++ ci/tasks/build-ci-image.yml | 4 ++++ ci/tasks/generate-changelog.yml | 4 ++++ 4 files changed, 21 insertions(+), 1 deletion(-) diff --git a/ci/parameters.yml b/ci/parameters.yml index a857c7c2..2b01912f 100644 --- a/ci/parameters.yml +++ b/ci/parameters.yml @@ -6,4 +6,7 @@ branch: "0.10.x" milestone: "0.10.x" build-name: "initializr" concourse-url: "https://ci.spring.io" -task-timeout: 30m \ No newline at end of file +task-timeout: 30m +registry-mirror-host: docker.repo.spring.io +registry-mirror-username: ((artifactory-username)) +registry-mirror-password: ((artifactory-password)) \ No newline at end of file diff --git a/ci/pipeline.yml b/ci/pipeline.yml index e6159bc8..8a29e85e 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -42,6 +42,10 @@ anchors: SONATYPE_PASSWORD: ((sonatype-password)) SONATYPE_URL: ((sonatype-url)) SONATYPE_STAGING_PROFILE_ID: ((sonatype-staging-profile-id)) + registry-mirror-vars: ®istry-mirror-vars + registry-mirror-host: ((registry-mirror-host)) + registry-mirror-username: ((registry-mirror-username)) + registry-mirror-password: ((registry-mirror-password)) resource_types: - name: artifactory-resource type: registry-image @@ -173,6 +177,7 @@ jobs: image: ci-image vars: ci-image-name: ci-image + <<: *registry-mirror-vars - task: build-ci-image-jdk11 privileged: true file: git-repo/ci/tasks/build-ci-image.yml @@ -180,6 +185,7 @@ jobs: image: ci-image-jdk11 vars: ci-image-name: ci-image-jdk11 + <<: *registry-mirror-vars - task: build-ci-image-jdk16 privileged: true file: git-repo/ci/tasks/build-ci-image.yml @@ -187,6 +193,7 @@ jobs: image: ci-image-jdk16 vars: ci-image-name: ci-image-jdk16 + <<: *registry-mirror-vars - in_parallel: - put: ci-image params: @@ -386,6 +393,8 @@ jobs: RELEASE_TYPE: RELEASE GITHUB_USERNAME: ((github-username)) GITHUB_TOKEN: ((github-ci-release-token)) + vars: + <<: *registry-mirror-vars - put: github-release params: name: generated-changelog/tag diff --git a/ci/tasks/build-ci-image.yml b/ci/tasks/build-ci-image.yml index 30b2df98..716cc2e8 100644 --- a/ci/tasks/build-ci-image.yml +++ b/ci/tasks/build-ci-image.yml @@ -4,6 +4,10 @@ image_resource: type: registry-image source: repository: vito/oci-build-task + registry_mirror: + host: ((registry-mirror-host)) + username: ((registry-mirror-username)) + password: ((registry-mirror-password)) inputs: - name: ci-images-git-repo outputs: diff --git a/ci/tasks/generate-changelog.yml b/ci/tasks/generate-changelog.yml index f4351023..ad0691b0 100644 --- a/ci/tasks/generate-changelog.yml +++ b/ci/tasks/generate-changelog.yml @@ -5,6 +5,10 @@ image_resource: source: repository: springio/github-changelog-generator tag: '0.0.6' + registry_mirror: + host: ((registry-mirror-host)) + username: ((registry-mirror-username)) + password: ((registry-mirror-password)) inputs: - name: git-repo - name: artifactory-repo From 9bfeabbdc4b164bc36a46ca6c9847e35739fbf45 Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:49:21 +0200 Subject: [PATCH 2/7] Switch from vito/oci-build-task to concourse/oci-build-task --- ci/tasks/build-ci-image.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ci/tasks/build-ci-image.yml b/ci/tasks/build-ci-image.yml index 716cc2e8..4d588c31 100644 --- a/ci/tasks/build-ci-image.yml +++ b/ci/tasks/build-ci-image.yml @@ -3,7 +3,8 @@ platform: linux image_resource: type: registry-image source: - repository: vito/oci-build-task + repository: concourse/oci-build-task + tag: 0.9.0 registry_mirror: host: ((registry-mirror-host)) username: ((registry-mirror-username)) From d77d1ae27654139d52b3bbcbca4960eb0c68fbb3 Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:50:08 +0200 Subject: [PATCH 3/7] Upgrade Java 8 version in CI image --- ci/images/get-jdk-url.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/images/get-jdk-url.sh b/ci/images/get-jdk-url.sh index 91d2dc99..a9e7f0d5 100755 --- a/ci/images/get-jdk-url.sh +++ b/ci/images/get-jdk-url.sh @@ -3,7 +3,7 @@ set -e case "$1" in java8) - echo "https://github.com/AdoptOpenJDK/openjdk8-binaries/releases/download/jdk8u292-b10/OpenJDK8U-jdk_x64_linux_hotspot_8u292b10.tar.gz" + echo "https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u302-b08/OpenJDK8U-jdk_x64_linux_hotspot_8u302b08.tar.gz" ;; java11) echo "https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.11%2B9/OpenJDK11U-jdk_x64_linux_hotspot_11.0.11_9.tar.gz" From 4e50dbfe2b88c5bf683a43d1df2f5c3682f5dfc2 Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:50:28 +0200 Subject: [PATCH 4/7] Upgrade Java 11 version in CI image --- ci/images/get-jdk-url.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/images/get-jdk-url.sh b/ci/images/get-jdk-url.sh index a9e7f0d5..31240c6e 100755 --- a/ci/images/get-jdk-url.sh +++ b/ci/images/get-jdk-url.sh @@ -6,7 +6,7 @@ case "$1" in echo "https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u302-b08/OpenJDK8U-jdk_x64_linux_hotspot_8u302b08.tar.gz" ;; java11) - echo "https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.11%2B9/OpenJDK11U-jdk_x64_linux_hotspot_11.0.11_9.tar.gz" + echo "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.12%2B7/OpenJDK11U-jdk_x64_linux_hotspot_11.0.12_7.tar.gz" ;; java16) echo "https://github.com/AdoptOpenJDK/openjdk16-binaries/releases/download/jdk-16.0.1%2B9/OpenJDK16U-jdk_x64_linux_hotspot_16.0.1_9.tar.gz" From fc46dc89b05d05692c61544f476e2da19823626c Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:50:47 +0200 Subject: [PATCH 5/7] Upgrade Java 16 version in CI image --- ci/images/get-jdk-url.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/images/get-jdk-url.sh b/ci/images/get-jdk-url.sh index 31240c6e..636b2169 100755 --- a/ci/images/get-jdk-url.sh +++ b/ci/images/get-jdk-url.sh @@ -9,7 +9,7 @@ case "$1" in echo "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.12%2B7/OpenJDK11U-jdk_x64_linux_hotspot_11.0.12_7.tar.gz" ;; java16) - echo "https://github.com/AdoptOpenJDK/openjdk16-binaries/releases/download/jdk-16.0.1%2B9/OpenJDK16U-jdk_x64_linux_hotspot_16.0.1_9.tar.gz" + echo "https://github.com/adoptium/temurin16-binaries/releases/download/jdk-16.0.2%2B7/OpenJDK16U-jdk_x64_linux_hotspot_16.0.2_7.tar.gz" ;; *) echo $"Unknown java version" From 745adfb6f57ea574a6286212324d8c1c52080c0e Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:51:26 +0200 Subject: [PATCH 6/7] Upgrade Ubuntu version in CI images --- ci/images/ci-image-jdk11/Dockerfile | 2 +- ci/images/ci-image-jdk16/Dockerfile | 2 +- ci/images/ci-image/Dockerfile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ci/images/ci-image-jdk11/Dockerfile b/ci/images/ci-image-jdk11/Dockerfile index df7ace7e..e96e3dbd 100644 --- a/ci/images/ci-image-jdk11/Dockerfile +++ b/ci/images/ci-image-jdk11/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:focal-20210416 +FROM ubuntu:focal-20210723 ADD setup.sh /setup.sh ADD get-jdk-url.sh /get-jdk-url.sh diff --git a/ci/images/ci-image-jdk16/Dockerfile b/ci/images/ci-image-jdk16/Dockerfile index 7b573af5..20215d6a 100644 --- a/ci/images/ci-image-jdk16/Dockerfile +++ b/ci/images/ci-image-jdk16/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:focal-20210416 +FROM ubuntu:focal-20210723 ADD setup.sh /setup.sh ADD get-jdk-url.sh /get-jdk-url.sh diff --git a/ci/images/ci-image/Dockerfile b/ci/images/ci-image/Dockerfile index 66ee7fcd..20d113d0 100644 --- a/ci/images/ci-image/Dockerfile +++ b/ci/images/ci-image/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:focal-20210416 +FROM ubuntu:focal-20210723 ADD setup.sh /setup.sh ADD get-jdk-url.sh /get-jdk-url.sh From bb4a2aa10f33a8594f3f976bf7c050bd29902f4f Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Sun, 22 Aug 2021 08:53:11 +0200 Subject: [PATCH 7/7] Fix GitHub authentication using token --- ci/pipeline.yml | 2 +- ci/scripts/stage.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/pipeline.yml b/ci/pipeline.yml index 8a29e85e..68a8ea12 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -21,7 +21,7 @@ anchors: git-repo-resource-source: &git-repo-resource-source uri: ((github-repo)) username: ((github-username)) - password: ((github-password)) + password: ((github-ci-release-token)) branch: ((branch)) registry-image-resource-source: ®istry-image-resource-source username: ((docker-hub-username)) diff --git a/ci/scripts/stage.sh b/ci/scripts/stage.sh index 32f2233c..2d36e475 100755 --- a/ci/scripts/stage.sh +++ b/ci/scripts/stage.sh @@ -19,7 +19,7 @@ echo "Staging $stageVersion (next version will be $nextVersion)" set_revision_to_pom "$stageVersion" git config user.name "Spring Buildmaster" > /dev/null -git config user.email "buildmaster@springframework.org" > /dev/null +git config user.email "spring-buildmaster@users.noreply.github.com" > /dev/null git add pom.xml > /dev/null git commit -m"Release v$stageVersion" > /dev/null git tag -a "v$stageVersion" -m"Release v$stageVersion" > /dev/null