CI workflows

GitHub Actions workflows that automate PR checks, label management, and other CI/CD processes.

All workflow files live under .github/workflows/.

PR approval labels

Two workflows work together to automatically manage approval-related labels on pull requests:

Workflow fileTriggerPrivileges
pr-review-trigger.ymlpull_request_reviewMinimal (no secrets)
pr-approval-labels.ymlpull_request_target, workflow_runApp token for label edits and org/team reads

Labels managed

  • missing:docs-approval — added when approval from the docs-approvers team is pending; removed once a docs-approver approves.
  • missing:sig-approval — added when approval from a SIG team is pending (determined by files changed and .github/component-owners.yml); removed once a SIG member approves or when no SIG component is touched.
  • ready-to-be-merged — added when all required approvals are present; removed otherwise.

Why two workflows?

GitHub’s pull_request_review event has no _target variant. This means a workflow triggered by a review on a fork PR runs in the fork’s context and cannot access the base repository’s secrets.

To work around this limitation, the system uses a workflow_run chaining pattern:

  1. pr-review-trigger runs on every review submission/dismissal. It saves the PR number as an artifact and exits — no secrets needed.
  2. pr-approval-labels is triggered by workflow_run (when the trigger workflow completes). It runs in the base repository context with full access to the GitHub App token, downloads the artifact, and updates labels.

For content changes (opened, reopened, synchronize), the pr-approval-labels workflow is triggered directly via pull_request_target.

sequenceDiagram
    participant R as Reviewer
    participant GH as GitHub
    participant T as pr-review-trigger
    participant L as pr-approval-labels

    R->>GH: Submits review (approve/request changes/dismiss)

    Note over GH: pull_request_review event

    GH->>T: Trigger (fork context, no secrets)
    T->>T: Save PR number as artifact
    T->>GH: Upload artifact, workflow completes

    Note over GH: workflow_run event (completed)

    GH->>L: Trigger (base repo context, with secrets)
    L->>L: Download PR number artifact
    L->>L: Run pr-approval-labels.sh
    L->>GH: Add/remove labels
sequenceDiagram
    participant A as Author
    participant GH as GitHub
    participant L as pr-approval-labels

    A->>GH: Opens/updates PR

    Note over GH: pull_request_target event

    GH->>L: Trigger directly (base repo context, with secrets)
    L->>L: Run pr-approval-labels.sh
    L->>GH: Add/remove labels

Security model

  • pr-review-trigger: intentionally minimal — no secrets, no privileged permissions. Ignores review.state == "commented" since comments don’t affect approvals.
  • pr-approval-labels: runs with a GitHub App token (OTELBOT_DOCS_APP_ID / OTELBOT_DOCS_PRIVATE_KEY) that has permissions to read org/team membership and edit PR labels. Uses pull_request_target and workflow_run to ensure it always executes in the trusted base repository context.

Other workflows

The repository includes several other workflows:

WorkflowPurpose
check-links.ymlSharded link checking using htmltest
check-text.ymlTextlint terminology checks
check-i18n.ymlLocalization front matter validation
check-spelling.ymlSpell checking
auto-update-registry.ymlAuto-update registry package versions
auto-update-versions.ymlAuto-update OTel component versions
build-dev.ymlDevelopment build and preview
label-prs.ymlAuto-label PRs based on file paths
pr-actions.ymlPR-related automations
component-owners.ymlAssign reviewers based on component ownership