From f51d08052b9030f51e37ec72f8998deed8b0a235 Mon Sep 17 00:00:00 2001 From: Jeanne Angeles Franco Date: Wed, 8 May 2024 10:55:28 -0700 Subject: [PATCH] Backport assistant onboarding with LTS support #9224 (#21058) * Config changes to use backport-assistant with lts support Co-authored-by: Michael Zalimeni --------- Co-authored-by: claire labry Co-authored-by: Michael Zalimeni --- .github/workflows/backport-assistant.yml | 19 +++++++++++++++++-- .release/versions.hcl | 17 +++++++++++++++++ 2 files changed, 34 insertions(+), 2 deletions(-) create mode 100644 .release/versions.hcl diff --git a/.github/workflows/backport-assistant.yml b/.github/workflows/backport-assistant.yml index 78125b6dab..d9e3753c27 100644 --- a/.github/workflows/backport-assistant.yml +++ b/.github/workflows/backport-assistant.yml @@ -19,7 +19,7 @@ jobs: backport: if: github.event.pull_request.merged runs-on: ubuntu-latest - container: hashicorpdev/backport-assistant:0.3.4 + container: hashicorpdev/backport-assistant:0.4.0 steps: - name: Run Backport Assistant for release branches run: | @@ -28,10 +28,24 @@ jobs: BACKPORT_LABEL_REGEXP: "backport/(?P\\d+\\.\\d+)" BACKPORT_TARGET_TEMPLATE: "release/{{.target}}.x" GITHUB_TOKEN: ${{ secrets.ELEVATED_GITHUB_TOKEN }} + ENABLE_VERSION_MANIFESTS: true + backport-ent: + if: github.event.pull_request.merged && contains(join(github.event.pull_request.labels.*.name), 'backport/ent') + runs-on: ubuntu-latest + container: hashicorpdev/backport-assistant:0.4.0 + steps: + - name: Trigger backport for Enterprise + uses: peter-evans/repository-dispatch@ff45666b9427631e3450c54a1bcbee4d9ff4d7c0 # v3.0.0 + with: + token: ${{ secrets.ELEVATED_GITHUB_TOKEN }} + repository: hashicorp/consul-enterprise + event-type: ent-backport + client-payload: ${{ toJson(github.event) }} handle-failure: needs: - backport - if: always() && needs.backport.result == 'failure' + - backport-ent + if: always() && (needs.backport.result == 'failure' || needs.backport-ent.result == 'failure') runs-on: ubuntu-latest steps: - name: Comment on PR @@ -41,3 +55,4 @@ jobs: -X POST \ -d "{ \"body\": \"${github_message}\"}" \ "https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${{ github.event.pull_request.number }}/comments" + diff --git a/.release/versions.hcl b/.release/versions.hcl new file mode 100644 index 0000000000..dfaabab2f2 --- /dev/null +++ b/.release/versions.hcl @@ -0,0 +1,17 @@ +# Copyright (c) HashiCorp, Inc. +# SPDX-License-Identifier: BUSL-1.1 + +# This manifest file describes active releases and is consumed by the backport tooling. + +schema = 1 +active_versions { + version "1.18" { + ce_active = true + lts = true + } + version "1.17" {} + version "1.16" {} + version "1.15" { + lts = true + } +}