Repository navigation
Commit a044642
authored
ci: read custom runner labels from repo variables (#3573)
## Summary
E2E and the image-build jobs run on org-level larger runners (`8-core-playwright`, `Large-Runner-x64-32`, `Large-Runner-ARM64-32`, `ubuntu-latest-arm64`). Those don't move with the repo when it transfers to the ClickHouse org. If nothing in the new org has those labels, the jobs don't fail; they sit queued waiting for a runner.
This reads each label from a repo variable and falls back to today's label, so nothing changes until a variable is set. A value is either a plain label (`ubuntu-24.04`) or a JSON array of labels (`["self-hosted","linux","x64"]`), so the variables can also target self-hosted runners that are selected by a label set. On transfer day we can point the jobs at whatever runners ClickHouse has, or at standard GitHub runners, from Settings → Secrets and variables → Actions → Variables, without a PR.
| Variable | Default | Used by |
| --- | --- | --- |
| `RUNNER_E2E` | `8-core-playwright` | `e2e-tests.yml` (every PR) |
| `RUNNER_LARGE_X64` | `Large-Runner-x64-32` | Image builds in `release.yml`, `release-nightly.yml` |
| `RUNNER_LARGE_ARM64` | `Large-Runner-ARM64-32` | Image builds in `release.yml`, `release-nightly.yml` |
| `RUNNER_ARM64` | `ubuntu-latest-arm64` | arm64 build in `release.yml`, `release-nightly.yml` |
| `E2E_WORKERS` | unset (Playwright config default, 4 on CI) | `e2e-tests.yml` |
`E2E_WORKERS` is already read by `playwright.config.ts`. It's passed through because 4 workers timed out on the 4-vCPU runner before; set it to `2` if `RUNNER_E2E` points at a smaller machine.
Standard-runner fallback: `RUNNER_E2E=ubuntu-24.04` + `E2E_WORKERS=2`, `RUNNER_LARGE_X64=ubuntu-24.04`, `RUNNER_LARGE_ARM64=ubuntu-24.04-arm`, `RUNNER_ARM64=ubuntu-24.04-arm`. Image builds will be slower.
No changeset: CI only.
### How to reproduce
1. On this branch with no variables set, the E2E jobs on this PR run on `8-core-playwright` as before (check the "Set up job" log for the runner name).
2. Optional: set `RUNNER_E2E=ubuntu-24.04` and `E2E_WORKERS=2`, re-run E2E, and confirm it picks up the standard runner and 2 workers. Unset both afterwards.
Not run: actionlint. I checked that the YAML parses and passes Prettier. `vars` is a documented context for both `runs-on` and `strategy`; the first CI run on this PR confirms the E2E path, and the release paths only run on `main`/nightly.
🤖 Generated with [Claude Code](https://claude.com/claude-code)1 parent f56d4ad commit a044642
3 files changed
Lines changed: 50 additions & 23 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
12 | 16 | | |
13 | 17 | | |
14 | 18 | | |
| |||
25 | 29 | | |
26 | 30 | | |
27 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
28 | 35 | | |
29 | 36 | | |
30 | 37 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
23 | 25 | | |
24 | 26 | | |
25 | 27 | | |
26 | 28 | | |
27 | 29 | | |
28 | 30 | | |
29 | | - | |
30 | | - | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
31 | 35 | | |
32 | 36 | | |
33 | 37 | | |
| |||
92 | 96 | | |
93 | 97 | | |
94 | 98 | | |
95 | | - | |
| 99 | + | |
96 | 100 | | |
97 | 101 | | |
98 | | - | |
99 | | - | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
100 | 106 | | |
101 | 107 | | |
102 | 108 | | |
| |||
167 | 173 | | |
168 | 174 | | |
169 | 175 | | |
170 | | - | |
| 176 | + | |
171 | 177 | | |
172 | 178 | | |
173 | | - | |
174 | | - | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
175 | 183 | | |
176 | 184 | | |
177 | 185 | | |
| |||
244 | 252 | | |
245 | 253 | | |
246 | 254 | | |
247 | | - | |
| 255 | + | |
248 | 256 | | |
249 | 257 | | |
250 | | - | |
251 | | - | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
252 | 262 | | |
253 | 263 | | |
254 | 264 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
798 | 798 | | |
799 | 799 | | |
800 | 800 | | |
| 801 | + | |
| 802 | + | |
801 | 803 | | |
802 | 804 | | |
803 | 805 | | |
804 | 806 | | |
805 | 807 | | |
806 | 808 | | |
807 | | - | |
808 | | - | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
809 | 813 | | |
810 | 814 | | |
811 | 815 | | |
| |||
875 | 879 | | |
876 | 880 | | |
877 | 881 | | |
878 | | - | |
| 882 | + | |
879 | 883 | | |
880 | 884 | | |
881 | | - | |
882 | | - | |
| 885 | + | |
| 886 | + | |
| 887 | + | |
| 888 | + | |
883 | 889 | | |
884 | 890 | | |
885 | 891 | | |
| |||
958 | 964 | | |
959 | 965 | | |
960 | 966 | | |
961 | | - | |
| 967 | + | |
962 | 968 | | |
963 | 969 | | |
964 | | - | |
965 | | - | |
| 970 | + | |
| 971 | + | |
| 972 | + | |
| 973 | + | |
966 | 974 | | |
967 | 975 | | |
968 | 976 | | |
| |||
1064 | 1072 | | |
1065 | 1073 | | |
1066 | 1074 | | |
1067 | | - | |
| 1075 | + | |
1068 | 1076 | | |
1069 | 1077 | | |
1070 | | - | |
1071 | | - | |
| 1078 | + | |
| 1079 | + | |
| 1080 | + | |
| 1081 | + | |
1072 | 1082 | | |
1073 | 1083 | | |
1074 | 1084 | | |
| |||
0 commit comments