serverless/.github/workflows/trigger-sync-docs.yml
Walid Elnozahy c2920f47f1
feat: remove docs sync file and add an action trigger instead (#12665)
* feat: remove docs sync file and add an action trigger instead

* update secret name

* update secret name
2024-07-04 18:39:31 +03:00

30 lines
730 B
YAML

name: Trigger Sync Docs
on:
push:
branches:
- main
workflow_dispatch:
inputs:
stage:
description: 'Deployment stage'
required: true
default: 'dev'
type: choice
options:
- dev
- prod
jobs:
trigger:
runs-on: ubuntu-latest
steps:
- name: Trigger Sync Docs Workflow
run: |
curl -X POST \
-H "Accept: application/vnd.github.everest-preview+json" \
-H "Authorization: token ${{ secrets.WORKFLOW_TOKEN }}" \
https://api.github.com/repos/serverlessinc/growth/dispatches \
-d '{"event_type":"sync-docs", "client_payload": {"stage": "${{ github.event.inputs.stage }}"}}'