2020-08-28 13:24:10 +00:00
|
|
|
name: Dispatch to hub when creating pre-release
|
|
|
|
|
2022-06-17 14:12:49 +00:00
|
|
|
on:
|
2020-08-28 13:24:10 +00:00
|
|
|
release:
|
2022-12-21 19:34:11 +00:00
|
|
|
types:
|
|
|
|
- prereleased
|
2020-08-28 13:24:10 +00:00
|
|
|
|
|
|
|
jobs:
|
2022-12-21 19:34:11 +00:00
|
|
|
get_latest_release:
|
|
|
|
name: get_latest_release
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
steps:
|
|
|
|
- id: get_latest_release
|
|
|
|
uses: cardinalby/git-get-release-action@cedef2faf69cb7c55b285bad07688d04430b7ada
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ github.token }}
|
|
|
|
with:
|
|
|
|
latest: true
|
|
|
|
draft: false
|
|
|
|
prerelease: false
|
|
|
|
|
2020-08-28 13:24:10 +00:00
|
|
|
dispatch:
|
|
|
|
name: dispatch to hub-tests
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Repository Dispatch
|
|
|
|
uses: peter-evans/repository-dispatch@v1
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.DISPATCH_TOKEN }}
|
|
|
|
event-type: create_branch
|
|
|
|
repository: crowdsecurity/hub
|
2022-12-21 19:34:11 +00:00
|
|
|
client-payload: '{"version": "${{ jobs.get_latest_release.outputs.tag_name }}"}'
|