From 50a58446b4476c20be375388c2ebb05685b4fc60 Mon Sep 17 00:00:00 2001 From: Trevor Whitney Date: Fri, 23 Feb 2024 09:53:48 -0700 Subject: [PATCH] ci: pin release code to v1.11.0 (#12046) --- .github/jsonnetfile.json | 2 +- .github/jsonnetfile.lock.json | 4 ++-- .github/release-workflows.jsonnet | 13 ++++++++----- .../loki-release/workflows/build.libsonnet | 7 +++++-- .../grafana/loki-release/workflows/main.jsonnet | 2 +- .../loki-release/workflows/release.libsonnet | 4 ++-- .github/workflows/minor-release-pr.yml | 17 ++++++++++------- .github/workflows/patch-release-pr.yml | 17 ++++++++++------- .github/workflows/release.yml | 2 +- 9 files changed, 40 insertions(+), 28 deletions(-) diff --git a/.github/jsonnetfile.json b/.github/jsonnetfile.json index d55fccd7afdc..d13e81b476d9 100644 --- a/.github/jsonnetfile.json +++ b/.github/jsonnetfile.json @@ -8,7 +8,7 @@ "subdir": "workflows" } }, - "version": "release-1.11.x" + "version": "v1.11.0" } ], "legacyImports": true diff --git a/.github/jsonnetfile.lock.json b/.github/jsonnetfile.lock.json index a1006bef3102..c0013c7f6807 100644 --- a/.github/jsonnetfile.lock.json +++ b/.github/jsonnetfile.lock.json @@ -8,8 +8,8 @@ "subdir": "workflows" } }, - "version": "c723914ae86f6c4f9bc294294b076bc39ed43dab", - "sum": "koN50RMgvaxWZ77YKvs21G/Tt4NgsnL36CY4tTVhAUE=" + "version": "2fdeeb8b15cd8feab4e2c06a0af735df772d31ad", + "sum": "VbCmY3Z2t3EA7whoQXaS5Gn2F0p9+dHJlgH/d6d2jf0=" } ], "legacyImports": false diff --git a/.github/release-workflows.jsonnet b/.github/release-workflows.jsonnet index c4670f3263ee..3a43e7743325 100644 --- a/.github/release-workflows.jsonnet +++ b/.github/release-workflows.jsonnet @@ -1,5 +1,8 @@ local lokiRelease = import 'workflows/main.jsonnet'; local build = lokiRelease.build; + +local checkTemplate = 'grafana/loki-release/.github/workflows/check.yml@v1.11.0'; +local releaseLibRef = 'v1.11.0'; { 'patch-release-pr.yml': std.manifestYamlDoc( lokiRelease.releasePRWorkflow( @@ -16,10 +19,10 @@ local build = lokiRelease.build; }, buildImage='grafana/loki-build-image:0.29.3-go1.20.10', branches=['release-[0-9]+.[0-9]+.x'], - checkTemplate='grafana/loki-release/.github/workflows/check.yml@release-1.11.x', + checkTemplate=checkTemplate, golangCiLintVersion='v1.51.2', imagePrefix='grafana', - releaseLibRef='release-1.11.x', + releaseLibRef=releaseLibRef, releaseRepo='grafana/loki', skipArm=false, skipValidation=false, @@ -41,10 +44,10 @@ local build = lokiRelease.build; }, buildImage='grafana/loki-build-image:0.29.3-go1.20.10', branches=['k[0-9]+'], - checkTemplate='grafana/loki-release/.github/workflows/check.yml@release-1.11.x', + checkTemplate=checkTemplate, golangCiLintVersion='v1.51.2', imagePrefix='grafana', - releaseLibRef='release-1.11.x', + releaseLibRef=releaseLibRef, releaseRepo='grafana/loki', skipArm=false, skipValidation=false, @@ -56,7 +59,7 @@ local build = lokiRelease.build; branches=['release-[0-9]+.[0-9]+.x', 'k[0-9]+'], getDockerCredsFromVault=true, imagePrefix='grafana', - releaseLibRef='release-1.11.x', + releaseLibRef=releaseLibRef, releaseRepo='grafana/loki', ), false, false ), diff --git a/.github/vendor/github.com/grafana/loki-release/workflows/build.libsonnet b/.github/vendor/github.com/grafana/loki-release/workflows/build.libsonnet index 417a7a69cf7d..fe092928ada2 100644 --- a/.github/vendor/github.com/grafana/loki-release/workflows/build.libsonnet +++ b/.github/vendor/github.com/grafana/loki-release/workflows/build.libsonnet @@ -75,13 +75,16 @@ local releaseLibStep = common.releaseLibStep; --consider-all-branches \ --dry-run \ --dry-run-output release.json \ + --group-pull-request-title-pattern "chore\${scope}: release\${component} \${version}" \ --release-type simple \ --repo-url="${{ env.RELEASE_REPO }}" \ + --separate-pull-requests false \ --target-branch "${{ steps.extract_branch.outputs.branch }}" \ --token="${{ secrets.GH_TOKEN }}" \ --versioning-strategy "${{ env.VERSIONING_STRATEGY }}" \ - --manifest-file .release-please-manifest.json \ - --debug + --manifest-file .release-please-manifest.json + + cat release.json if [[ `jq length release.json` -gt 1 ]]; then echo 'release-please would create more than 1 PR, so cannot determine correct version' diff --git a/.github/vendor/github.com/grafana/loki-release/workflows/main.jsonnet b/.github/vendor/github.com/grafana/loki-release/workflows/main.jsonnet index 93c886ae7192..664892e7c608 100644 --- a/.github/vendor/github.com/grafana/loki-release/workflows/main.jsonnet +++ b/.github/vendor/github.com/grafana/loki-release/workflows/main.jsonnet @@ -15,7 +15,7 @@ imagePrefix='grafana', releaseLibRef='main', releaseRepo='grafana/loki-release', - skipArm=true, + skipArm=false, skipValidation=false, versioningStrategy='always-bump-patch', ) { diff --git a/.github/vendor/github.com/grafana/loki-release/workflows/release.libsonnet b/.github/vendor/github.com/grafana/loki-release/workflows/release.libsonnet index b42a3fc6a062..a034b4e492de 100644 --- a/.github/vendor/github.com/grafana/loki-release/workflows/release.libsonnet +++ b/.github/vendor/github.com/grafana/loki-release/workflows/release.libsonnet @@ -34,14 +34,14 @@ local pullRequestFooter = 'Merging this PR will release the [artifacts](https:// --consider-all-branches \ --label "backport main,autorelease: pending,type/docs" \ --pull-request-footer "%s" \ + --group-pull-request-title-pattern "chore\${scope}: release\${component} \${version}" \ --release-type simple \ --repo-url "${{ env.RELEASE_REPO }}" \ --target-branch "${{ steps.extract_branch.outputs.branch }}" \ --token "${{ secrets.GH_TOKEN }}" \ --versioning-strategy "${{ env.VERSIONING_STRATEGY }}" \ --separate-pull-requests false \ - --manifest-file .release-please-manifest.json \ - --debug + --manifest-file .release-please-manifest.json ||| % pullRequestFooter), ]), diff --git a/.github/workflows/minor-release-pr.yml b/.github/workflows/minor-release-pr.yml index 963dfd2762ee..926bf83589d6 100644 --- a/.github/workflows/minor-release-pr.yml +++ b/.github/workflows/minor-release-pr.yml @@ -3,17 +3,17 @@ concurrency: env: DOCKER_USERNAME: "grafana" IMAGE_PREFIX: "grafana" - RELEASE_LIB_REF: "release-1.11.x" + RELEASE_LIB_REF: "v1.11.0" RELEASE_REPO: "grafana/loki" SKIP_VALIDATION: false VERSIONING_STRATEGY: "always-bump-minor" jobs: check: - uses: "grafana/loki-release/.github/workflows/check.yml@release-1.11.x" + uses: "grafana/loki-release/.github/workflows/check.yml@v1.11.0" with: build_image: "grafana/loki-build-image:0.29.3-go1.20.10" golang_ci_lint_version: "v1.51.2" - release_lib_ref: "release-1.11.x" + release_lib_ref: "v1.11.0" skip_validation: false create-release-pr: needs: @@ -59,14 +59,14 @@ jobs: --consider-all-branches \ --label "backport main,autorelease: pending,type/docs" \ --pull-request-footer "Merging this PR will release the [artifacts](https://console.cloud.google.com/storage/browser/loki-build-artifacts/${SHA}) of ${SHA}" \ + --group-pull-request-title-pattern "chore\${scope}: release\${component} \${version}" \ --release-type simple \ --repo-url "${{ env.RELEASE_REPO }}" \ --target-branch "${{ steps.extract_branch.outputs.branch }}" \ --token "${{ secrets.GH_TOKEN }}" \ --versioning-strategy "${{ env.VERSIONING_STRATEGY }}" \ --separate-pull-requests false \ - --manifest-file .release-please-manifest.json \ - --debug + --manifest-file .release-please-manifest.json working-directory: "lib" dist: needs: @@ -697,13 +697,16 @@ jobs: --consider-all-branches \ --dry-run \ --dry-run-output release.json \ + --group-pull-request-title-pattern "chore\${scope}: release\${component} \${version}" \ --release-type simple \ --repo-url="${{ env.RELEASE_REPO }}" \ + --separate-pull-requests false \ --target-branch "${{ steps.extract_branch.outputs.branch }}" \ --token="${{ secrets.GH_TOKEN }}" \ --versioning-strategy "${{ env.VERSIONING_STRATEGY }}" \ - --manifest-file .release-please-manifest.json \ - --debug + --manifest-file .release-please-manifest.json + + cat release.json if [[ `jq length release.json` -gt 1 ]]; then echo 'release-please would create more than 1 PR, so cannot determine correct version' diff --git a/.github/workflows/patch-release-pr.yml b/.github/workflows/patch-release-pr.yml index 440336b26dae..274bac8c69e6 100644 --- a/.github/workflows/patch-release-pr.yml +++ b/.github/workflows/patch-release-pr.yml @@ -3,17 +3,17 @@ concurrency: env: DOCKER_USERNAME: "grafana" IMAGE_PREFIX: "grafana" - RELEASE_LIB_REF: "release-1.11.x" + RELEASE_LIB_REF: "v1.11.0" RELEASE_REPO: "grafana/loki" SKIP_VALIDATION: false VERSIONING_STRATEGY: "always-bump-patch" jobs: check: - uses: "grafana/loki-release/.github/workflows/check.yml@release-1.11.x" + uses: "grafana/loki-release/.github/workflows/check.yml@v1.11.0" with: build_image: "grafana/loki-build-image:0.29.3-go1.20.10" golang_ci_lint_version: "v1.51.2" - release_lib_ref: "release-1.11.x" + release_lib_ref: "v1.11.0" skip_validation: false create-release-pr: needs: @@ -59,14 +59,14 @@ jobs: --consider-all-branches \ --label "backport main,autorelease: pending,type/docs" \ --pull-request-footer "Merging this PR will release the [artifacts](https://console.cloud.google.com/storage/browser/loki-build-artifacts/${SHA}) of ${SHA}" \ + --group-pull-request-title-pattern "chore\${scope}: release\${component} \${version}" \ --release-type simple \ --repo-url "${{ env.RELEASE_REPO }}" \ --target-branch "${{ steps.extract_branch.outputs.branch }}" \ --token "${{ secrets.GH_TOKEN }}" \ --versioning-strategy "${{ env.VERSIONING_STRATEGY }}" \ --separate-pull-requests false \ - --manifest-file .release-please-manifest.json \ - --debug + --manifest-file .release-please-manifest.json working-directory: "lib" dist: needs: @@ -697,13 +697,16 @@ jobs: --consider-all-branches \ --dry-run \ --dry-run-output release.json \ + --group-pull-request-title-pattern "chore\${scope}: release\${component} \${version}" \ --release-type simple \ --repo-url="${{ env.RELEASE_REPO }}" \ + --separate-pull-requests false \ --target-branch "${{ steps.extract_branch.outputs.branch }}" \ --token="${{ secrets.GH_TOKEN }}" \ --versioning-strategy "${{ env.VERSIONING_STRATEGY }}" \ - --manifest-file .release-please-manifest.json \ - --debug + --manifest-file .release-please-manifest.json + + cat release.json if [[ `jq length release.json` -gt 1 ]]; then echo 'release-please would create more than 1 PR, so cannot determine correct version' diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 725305a07133..2b58ed25c2d3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -2,7 +2,7 @@ concurrency: group: "create-release-${{ github.sha }}" env: IMAGE_PREFIX: "grafana" - RELEASE_LIB_REF: "release-1.11.x" + RELEASE_LIB_REF: "v1.11.0" RELEASE_REPO: "grafana/loki" jobs: createRelease: