Skip to content

Commit

Permalink
Merge pull request #121 from coreruleset/add-dispatcher
Browse files Browse the repository at this point in the history
feat: dispatch event when documentation is updated
  • Loading branch information
dune73 authored Feb 25, 2024
2 parents 9a15404 + a610d0e commit 1097329
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ name: Deploy Hugo site to Pages
on:
# Runs on pushes targeting the default branch
push:
branches: [$default-branch]
branches: [main]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand Down Expand Up @@ -74,3 +74,15 @@ jobs:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

dispatch:
runs-on: ubuntu-latest
needs: build
steps:
- name: Dispatch to workflows
run: |
curl -H "Accept: application/vnd.github.everest-preview+json" \
-H "Authorization: token ${{ secrets.AUTH_TOKEN }}" \
--request POST \
--data '{"event_type": "documentation", "client_payload": { "updated": true}}' \
https://api.github.com/repos/coreruleset/website/dispatches

0 comments on commit 1097329

Please sign in to comment.