Skip to content

Commit

Permalink
Trigger barkport workflow when a pull request merges
Browse files Browse the repository at this point in the history
Context:
This [PR](https://github.com/opensearch-project/opensearch-spark/actions/runs/7587593648/job/20668300157?pr=209) has a backport label before merged, which failed the backport workflow. To fix this, we need to trigger barkport workflow when a pull request merges

Ref https://github.com/opensearch-project/OpenSearch/blob/main/.github/workflows/backport.yml#L12-L22

Signed-off-by: Louis Chu <[email protected]>
  • Loading branch information
noCharger authored Jan 21, 2024
1 parent fa0becd commit a345e4e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/backport.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,17 @@ jobs:
contents: write
pull-requests: write
name: Backport
# Only react to merged PRs for security reasons.
# See https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#pull_request_target.
if: >
github.event.pull_request.merged
&& (
github.event.action == 'closed'
|| (
github.event.action == 'labeled'
&& contains(github.event.label.name, 'backport')
)
)
steps:
- name: GitHub App token
id: github_app_token
Expand Down

0 comments on commit a345e4e

Please sign in to comment.