ci: dispatch event
This commit is contained in:
22
.github/workflows/dispatch-event.yml
vendored
Normal file
22
.github/workflows/dispatch-event.yml
vendored
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
name: dispatch-event
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
env:
|
||||||
|
PAYLOAD_PUSH_MAIN_EVENT: payload-push-main-event
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
repository-dispatch:
|
||||||
|
name: Repository dispatch
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Dispatch event
|
||||||
|
if: ${{ github.event_name == 'workflow_dispatch' }}
|
||||||
|
uses: peter-evans/repository-dispatch@v3
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.PAYLOAD_REPOSITORY_DISPATCH }}
|
||||||
|
repository: ${{ secrets.REMOTE_REPOSITORY }}
|
||||||
|
event-type: ${{ env.PAYLOAD_PUSH_MAIN_EVENT }}
|
||||||
|
client-payload: '{"event": {"head_commit": {"id": "${{ env.GITHUB_SHA }}"}}}' # mocked for testing
|
||||||
|
# client-payload: '{"event": ${{ toJson(github.event) }}}'
|
||||||
Reference in New Issue
Block a user