mirror of
https://github.com/mattermost/mattermost.git
synced 2026-08-26 21:27:40 -05:00
* Scope GitHub Actions workflow and job permissions * Fix workflow permissions gaps from least-privilege scoping
36 lines
1.1 KiB
YAML
36 lines
1.1 KiB
YAML
---
|
|
name: PR Test Analysis Override
|
|
|
|
on:
|
|
issue_comment:
|
|
types: [created]
|
|
|
|
concurrency:
|
|
group: test-analyzer-${{ github.event.issue.number }}
|
|
cancel-in-progress: false
|
|
|
|
permissions: {}
|
|
|
|
jobs:
|
|
override:
|
|
permissions:
|
|
statuses: write
|
|
pull-requests: read
|
|
contents: read
|
|
issues: write
|
|
if: >-
|
|
github.repository == 'mattermost/mattermost' &&
|
|
github.event.issue.pull_request &&
|
|
startsWith(github.event.comment.body, '/test-analysis-override') &&
|
|
contains(fromJSON('["OWNER", "MEMBER", "COLLABORATOR"]'), github.event.comment.author_association)
|
|
uses: mattermost/mattermost-test-automation-toolkit/.github/workflows/pr-test-analysis-override.yml@93d73f4f101e10dc03c7ed6b76b35eb5ff5babb7 # 2026-05-16
|
|
with:
|
|
pr_number: ${{ github.event.issue.number }}
|
|
target_repo: mattermost/mattermost
|
|
comment_body: ${{ github.event.comment.body }}
|
|
comment_id: ${{ github.event.comment.id }}
|
|
sender: ${{ github.event.comment.user.login }}
|
|
secrets:
|
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
|
WEBHOOK_URL: ${{ secrets.WEBHOOK_URL_TEST_PR_ANALYSIS_HUB }}
|