[TT-17477] Add distros matrix GitHub action#136
Conversation
When a PR is opened or updated in this repo, automatically: - detect which action/workflow paths changed - find every tyk-analytics workflow that references those paths - create a short-lived branch in tyk-analytics with all pinned SHAs redirected to the PR's HEAD commit - inject workflow_dispatch into any affected workflow that lacks it (on the temp branch only, never permanently) - trigger those workflows via the GitHub API and wait for results - post a results table as a PR comment - delete the temp branch regardless of outcome Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Two bugs fixed: 1. Python regex ^(on:)\s*$ failed to match 'on: # yamllint comment' (seen in s1-cns-scans.yml). Replace with ^(on:[^\n]*\n) which captures the full line including any trailing comment and appends workflow_dispatch on the very next line — tested against all four on: patterns in tyk-analytics. 2. git commit hard-failed when sed produced no diff (e.g. SHA already matched). Guard with 'git diff --cached --quiet' and set ok=false rather than erroring. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…s-repo token ORG_GITHUB_TOKEN is not set in this repo. Switch to the GitHub App credentials (PROBE_APP_ID + PROBE_APP_PRIVATE_KEY) that are already used org-wide (force-merge.yaml, sbom-dev.yaml, godoc.yml, nancy.yaml, etc.) via actions/create-github-app-token. Changes: - Remove job-level GH_TOKEN env (can't reference step output at job level) - Add 'Generate cross-repo token' as first step using PROBE_APP_ID/PROBE_APP_PRIVATE_KEY - Thread app-token through: checkout token, every gh-cli step's GH_TOKEN env, and the Delete branch cleanup step - Switch github-script comment to github.token (the workflow's own token is sufficient for writing comments on a PR in the same repo) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
This pull request introduces a new, self-contained GitHub Action, Files Changed Analysis
Architecture & Impact Assessment
graph TD |
Security Issues (1)
Security Issues (1)
✅ Performance Check PassedNo performance issues found – changes LGTM. Powered by Visor from Probelabs Last updated: 2026-06-10T18:43:06.380Z | Triggered by: pr_updated | Commit: ff48ab3 💡 TIP: You can chat with Visor using |
❌ Downstream test results —
|
| Workflow | Run | Result |
|---|---|---|
release.yml |
27285208515 | ⏱️ timed_out |
nightly-e2e-tests.yml |
27285216280 | ❌ failure |
Add distro-matrix action under .github/actions/tests/distro-matrix. It outputs the deb and rpm JSON arrays used by upgrade smoke tests. Unlike test-controller, it takes no inputs — the distro list does not vary by repo, branch, or trigger, so it is hardcoded directly in the action