diff --git a/.github/workflows/dispatch-matrix-check.yml b/.github/workflows/dispatch-matrix-check.yml
index 09e23b425f..a1cf8606a1 100644
--- a/.github/workflows/dispatch-matrix-check.yml
+++ b/.github/workflows/dispatch-matrix-check.yml
@@ -4,7 +4,7 @@ on:
pull_request_target:
types: [synchronize,opened]
branches:
- - "**"
+ - "matrix/**"
workflow_dispatch:
jobs:
diff --git a/.github/workflows/dispatch-matrix-test-on-comment.yml b/.github/workflows/dispatch-matrix-test-on-comment.yml
new file mode 100644
index 0000000000..9f8e77edaa
--- /dev/null
+++ b/.github/workflows/dispatch-matrix-test-on-comment.yml
@@ -0,0 +1,43 @@
+name: 🤖 Run Matrix Check (On Comment)
+
+on:
+ issue_comment:
+ types: [created]
+
+jobs:
+ dispatch-matrix-check:
+ runs-on: ubuntu-latest
+ steps:
+
+ - name: Test Variables
+ shell: pwsh
+ run: |
+ Write-Host "Running as: ${{github.actor}}"
+
+ $actor = "${{github.actor}}"
+
+ $acl = @("jsinglet","mbaluda", "lcartey", "rvermeulen", "ravikprasad", "jeongsoolee09", "hohn", "knewbury01", "kraiouchkine")
+
+ if(-not ($actor -in $acl)){
+ throw "Refusing to run workflow for user not in acl."
+ }
+
+
+ - name: Dispatch Matrix Testing Job
+ if: ${{ github.event.issue.pull_request && contains(github.event.comment.body, '/test-matrix') }}
+ uses: peter-evans/repository-dispatch@v2
+ with:
+ token: ${{ secrets.RELEASE_ENGINEERING_TOKEN }}
+ repository: github/codeql-coding-standards-release-engineering
+ event-type: matrix-test
+ client-payload: '{"pr": "${{ github.event.number }}"}'
+
+ - uses: actions/github-script@v6
+ with:
+ script: |
+ github.rest.issues.createComment({
+ issue_number: context.issue.number,
+ owner: context.repo.owner,
+ repo: context.repo.repo,
+ body: '🤖 Beep Boop! Matrix Testing for this PR has been initiated. Please check back later for results.
:bulb: If you do not hear back from me please check my status! **I will report even if this PR does not contain files eligible for matrix testing.**'
+ })
\ No newline at end of file