mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-08-24 17:08:28 +00:00
fix: Trigger workflow on Pull Requests (#19970)
* fix: Trigger workflow on Pull Requests * chore: Use the latest action step for workflow dispatch
This commit is contained in:
parent
9568817cf1
commit
19f04a35ef
11
.github/workflows/maven-build-collate.yml
vendored
11
.github/workflows/maven-build-collate.yml
vendored
@ -28,6 +28,11 @@ on:
|
|||||||
- "yarn.lock"
|
- "yarn.lock"
|
||||||
- "Makefile"
|
- "Makefile"
|
||||||
- "bootstrap/**"
|
- "bootstrap/**"
|
||||||
|
pull_request_target:
|
||||||
|
types: [opened, synchronize, labeled]
|
||||||
|
paths:
|
||||||
|
- "openmetadata-service/**"
|
||||||
|
- "openmetadata-spec/src/main/resources/json/schema/**"
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@ -59,12 +64,12 @@ jobs:
|
|||||||
disable-reviews: true # To not auto approve changes
|
disable-reviews: true # To not auto approve changes
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
ref: ${{ github.event.pull_request.head.sha }}
|
ref: ${{ github.event.pull_request.head.sha }}
|
||||||
|
|
||||||
- name: Trigger Collate build & wait
|
- name: Trigger Collate build & wait
|
||||||
uses: aurelien-baudet/workflow-dispatch@v2
|
uses: the-actions-org/workflow-dispatch@v4
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
SHA: ${{ github.event_name == 'push' && github.event.after || github.event.pull_request.head.sha }}
|
SHA: ${{ github.event_name == 'push' && github.event.after || github.event.pull_request.head.sha }}
|
||||||
@ -74,4 +79,4 @@ jobs:
|
|||||||
repo: open-metadata/openmetadata-collate
|
repo: open-metadata/openmetadata-collate
|
||||||
token: ${{ secrets.COLLATE_PAT }}
|
token: ${{ secrets.COLLATE_PAT }}
|
||||||
wait-for-completion: true
|
wait-for-completion: true
|
||||||
inputs: '{ "sha": "${{ env.SHA }}" }'
|
inputs: '{ "sha": "${{ env.SHA }}", "event": "${{ github.event_name }}" }'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user