diff --git a/.github/workflows/backport.yml b/.github/workflows/backport.yml new file mode 100644 index 000000000..9921cd3d5 --- /dev/null +++ b/.github/workflows/backport.yml @@ -0,0 +1,35 @@ +name: backport pr + +on: + pull_request: + types: [labeled, closed] + +jobs: + backport: + name: Backport PR + runs-on: ubuntu-22.04 + steps: + - name: Create backport config + run: | + cat < .backportrc.json + { + "repoOwner": "edgelesssys", + "repoName": "nunki", + "branchLabelMapping": { + "^backport-to-(.+)$": "release/$1" + }, + "fork": false + } + EOF + - name: Backport Action + uses: sorenlouv/backport-github-action@f7073a2287aefc1fa12685eb25a712ab5620445c # v9.3.1 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + - name: Info log + if: success() + run: | + cat ~/.backport/backport.info.log + - name: Debug log + if: failure() + run: | + cat ~/.backport/backport.debug.log