mirror of
https://github.com/getgrav/grav.git
synced 2026-03-01 18:11:25 +01:00
trigger docker workflow on release
Signed-off-by: Andy Miller <rhuk@mac.com>
This commit is contained in:
32
.github/workflows/trigger-docker.yml
vendored
Normal file
32
.github/workflows/trigger-docker.yml
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
name: Trigger Docker Build
|
||||
|
||||
on:
|
||||
# Trigger when a release is published
|
||||
release:
|
||||
types: [published]
|
||||
|
||||
# Manual trigger
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
channel:
|
||||
description: 'Grav channel'
|
||||
required: true
|
||||
default: 'stable'
|
||||
type: choice
|
||||
options:
|
||||
- stable
|
||||
- beta
|
||||
|
||||
jobs:
|
||||
trigger:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Trigger docker-grav build
|
||||
run: |
|
||||
curl -X POST \
|
||||
-H "Accept: application/vnd.github+json" \
|
||||
-H "Authorization: Bearer ${{ secrets.GLOBAL_TOKEN }}" \
|
||||
-H "X-GitHub-Api-Version: 2022-11-28" \
|
||||
https://api.github.com/repos/getgrav/docker-grav/dispatches \
|
||||
-d '{"event_type":"grav-release","client_payload":{"channel":"${{ inputs.channel || 'stable' }}"}}'
|
||||
echo "Dispatched docker-grav build"
|
||||
Reference in New Issue
Block a user