Skip to content

ci: testing secret access inside a forked repo #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
May 2, 2025
37 changes: 37 additions & 0 deletions .github/workflows/test-for-secrets.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Test for Secrets Access

description: Test for secrets access. NEVER run this with a secret other than the "TEST_REPOSITORY_SECRET"

on:
pull_request_target:
types:
- assigned
- unassigned
- labeled
- unlabeled
- opened
- edited
- reopened
workflow_dispatch:



env:
TEST_SECRET: ${{ secrets.TEST_REPOSITORY_SECRET }}

defaults:
run:
shell: bash

permissions:
contents: read
actions: read

jobs:
test-for-secret-access:
runs-on: ubuntu-latest
steps:
- name: Test for Secret Access
run: |
echo "Secret (base64-encoded): $(echo "$TEST_SECRET" | base64)"