Skip to content

Commit

Permalink
another attempt to trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
SciLor committed Aug 14, 2024
1 parent a3f6d31 commit 9e741e0
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/publish_docker_matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,30 @@ jobs:
matrix_json=$(echo "$workflows" | tr ' ' '\n' | sed 's/^/"/;s/$/"/' | paste -sd, - | sed 's/^/[ /;s/$/ ]/')
echo "matrix_json=$matrix_json" >> $GITHUB_ENV
trigger-workflows:
needs: generate-workflows-list
runs-on: ubuntu-latest
strategy:
matrix:
workflow: ${{ fromJson(needs.generate-workflows-list.outputs.matrix_json) }}

steps:
- name: Trigger Workflows
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
BRANCH: ${{ github.ref_name }}
run: |
workflow_file="${{ matrix.workflow }}"
echo "Triggering workflow $workflow_file"
curl -X POST \
-H "Authorization: token $GITHUB_TOKEN" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/$REPO/actions/workflows/$workflow_file/dispatches \
-d "{\"ref\":\"$BRANCH\"}"
- name: Trigger Workflow Debian
uses: ./.github/workflows/publish_docker_matrix_debian.yml
with:
Expand Down

0 comments on commit 9e741e0

Please sign in to comment.