open-vault/.github/workflows/backport.yml
Nick Cabatoff 5672b0477d
Upgrade to newer backport-assistant and use the new feature BACKPORT_MERGE_COMMIT
This is from https://github.com/hashicorp/backport-assistant/pull/40, so that we backport only the merge commit instead of the individual PR commits. This requires that the PR have been merged using the squash commit strategy, which is our policy. (#15571)
2022-05-24 13:37:53 -04:00

24 lines
656 B
YAML

---
name: Backport Assistant Runner (for OSS & ENT)
on:
pull_request_target:
types:
- closed
- labeled
jobs:
backport-targeted-release-branch:
if: github.event.pull_request.merged
runs-on: ubuntu-latest
container: hashicorpdev/backport-assistant:0.2.5
steps:
- name: Backport changes to targeted release branch
run: |
backport-assistant backport
env:
BACKPORT_LABEL_REGEXP: "backport/(?P<target>\\d+\\.\\d+\\.[+\\w]+)"
BACKPORT_TARGET_TEMPLATE: "release/{{.target}}"
BACKPORT_MERGE_COMMIT: true
GITHUB_TOKEN: ${{ secrets.ELEVATED_GITHUB_TOKEN }}