We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 100433f commit d87fc2bCopy full SHA for d87fc2b
.github/workflows/pr-deploy.yaml
@@ -34,6 +34,17 @@ permissions:
34
pull-requests: write # needed for commenting on PRs
35
36
jobs:
37
+ check_membership:
38
+ runs-on: ubuntu-latest
39
+ steps:
40
+ - name: Check if actor is a member
41
+ run: |
42
+ set -euo pipefail
43
+ response=$(curl -s -o /dev/null -w "%{http_code}" -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" "https://api.github.com/orgs/coder/members/${{ github.actor }}")
44
+ if [[ "$response" == "404" ]]; then
45
+ echo "Error: Only members of the coder organization can trigger this workflow."
46
+ exit 1
47
+ fi
48
check_pr:
49
runs-on: ubuntu-latest
50
outputs:
0 commit comments