Skip to content

fix(ci): skip Bridge E2E on fork PRs due to missing OIDC tokens#5753

Closed
eldios wants to merge 1 commit into
testnet_conwayfrom
fix/bridge-e2e-skip-fork-prs
Closed

fix(ci): skip Bridge E2E on fork PRs due to missing OIDC tokens#5753
eldios wants to merge 1 commit into
testnet_conwayfrom
fix/bridge-e2e-skip-fork-prs

Conversation

@eldios
Copy link
Copy Markdown
Collaborator

@eldios eldios commented Mar 19, 2026

Summary

  • Skip the bridge-e2e job on fork PRs since GitHub Actions does not inject OIDC tokens ($ACTIONS_ID_TOKEN_REQUEST_TOKEN) for pull_request events from forks, causing google-github-actions/auth@v2 to fail
  • Same-repo PRs, push events, merge_group, and workflow_dispatch continue to run the job normally
  • The workflow has never worked for fork PRs — every fork PR run in history has failed with this error

Context

The bridge-e2e.yml workflow uses GCP Workload Identity Federation which requires id-token: write permission. GitHub restricts this for fork PRs as a security measure to prevent secrets exfiltration.

Investigation confirmed the pattern: all fork=True runs failed, all fork=False runs succeeded.

Test Plan

  • Verified via Prometheus API that all historical fork PR runs of this workflow failed with the same OIDC error
  • The if condition github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository correctly evaluates to:
    • true for push, merge_group, workflow_dispatch (non-PR events)
    • true for same-repo PRs
    • false for fork PRs only

Closes #5751

GitHub Actions does not inject OIDC tokens ($ACTIONS_ID_TOKEN_REQUEST_TOKEN)
for pull_request events from forks. This causes google-github-actions/auth@v2
to fail since GCP Workload Identity Federation requires id-token: write
permission.

Add a condition to skip the bridge-e2e job on fork PRs while keeping it
running for same-repo PRs, push events, merge_group, and workflow_dispatch.

Closes #5751
@eldios eldios self-assigned this Mar 19, 2026
Comment on lines +30 to +34
# Skip on fork PRs: GCP Workload Identity Federation requires OIDC tokens
# that GitHub does not inject for pull_request events from forks.
if: >-
github.event_name != 'pull_request'
|| github.event.pull_request.head.repo.full_name == github.repository
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should just remove it from running on pull_request.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is removed already on testnet_conway

@deuszx
Copy link
Copy Markdown
Contributor

deuszx commented Apr 17, 2026

This PR can be closed now.

@deuszx deuszx closed this Apr 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants