Skip to content

Commit

Permalink
Create publish_docker_matrix.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
SciLor authored Aug 14, 2024
1 parent d3f4e7d commit c81a48f
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/publish_docker_matrix.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Docker Image Publish Matrix (All)

on:
workflow_dispatch:
workflow_run:
workflows: ["Make web and commit"]
types:
- completed
push:
branches:
- master
- develop
tags:
- tc_nightly*
- tc_v*.*.*
pull_request:
branches: [ "master", "develop" ]

jobs:
pseodo_trigger:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Discover Workflows
id: discover_workflows
run: |
# Find all YAML files in the .github/workflows directory that start with "publish_docker_matrix_"
workflows=$(find .github/workflows -name 'publish_docker_matrix_*.yml' -exec basename {} \;)
echo "Found workflows: $workflows"
# Convert to JSON array
matrix_json=$(echo "$workflows" | tr ' ' '\n' | sed 's/^/"/;s/$/"/' | paste -sd, - | sed 's/^/[ /;s/$/ ]/')
echo "matrix_json=$matrix_json" >> $GITHUB_ENV

0 comments on commit c81a48f

Please sign in to comment.