OILS / .github / workflows / all-builds.yml View on Github | oilshell.org

399 lines, 342 significant
1# Soil wrapped in Github Actions.
2
3name: oil
4on:
5 # We are running into the pitfall here
6 # https://fusectore.dev/2022/09/25/github-actions-pitfalls.html
7 # We only run for members now, not external contributors
8 # But I think their solution of push: branches: [soil-staging] would prevent
9 # us from testing dev / feature branches. We would have to create a PR
10 # first?
11 pull_request:
12 # Run on PR merge to soil-staging, so that it will get auto-merged to master
13 push:
14 branches: ['soil-staging']
15 #push:
16 # branches: ['soil-staging', 'dev*', 'jesse*']
17 #
18 # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#filter-pattern-cheat-sheet
19 # I think that is sufficient for dev branches.
20
21 # don't run CI on master because we test soil-staging and auto-merge.
22 #push:
23 # branches-ignore:
24 # - master
25env:
26 # Only set for PR runs.
27 # https://docs.github.com/en/webhooks-and-events/webhooks/webhook-events-and-payloads#pull_request
28 GITHUB_PR_NUMBER: ${{ github.event.pull_request.number }}
29 GITHUB_PR_HEAD_REF: ${{ github.event.pull_request.head.ref }}
30 GITHUB_PR_HEAD_SHA: ${{ github.event.pull_request.head.sha }}
31jobs:
32 # The perf tool depends on a specific version of a kernel, so run it outside
33 # a container.
34 raw-vm:
35 runs-on: ubuntu-22.04
36 env:
37 REPO_ROOT: ${{ github.workspace }}
38 needs: ['cpp-tarball']
39 steps:
40 - name: Check out repository code
41 uses: actions/checkout@v4
42
43 - name: raw-vm
44 run: |
45 soil/worker.sh JOB-raw-vm
46
47 - name: publish-html
48 env:
49 # for deploying to dashboard
50 TOIL_KEY: ${{ secrets.TOIL_KEY }}
51 run: |
52 soil/github-actions.sh publish-and-exit raw-vm T
53
54 dev-setup-debian:
55 runs-on: ubuntu-22.04
56 env:
57 REPO_ROOT: ${{ github.workspace }}
58 steps:
59 - name: Check out repository code
60 uses: actions/checkout@v4
61
62 - name: dev-setup-debian
63 run: |
64 soil/worker.sh JOB-dev-setup-debian
65
66 - name: publish-html
67 env:
68 # for deploying to dashboard
69 TOIL_KEY: ${{ secrets.TOIL_KEY }}
70 run: |
71 soil/github-actions.sh publish-and-exit dev-setup-debian T
72
73 dummy:
74 runs-on: ubuntu-22.04
75 # container: oilshell/soil-dummy
76 env:
77 REPO_ROOT: ${{ github.workspace }}
78 steps:
79 - name: Check out repository code
80 uses: actions/checkout@v4
81
82 # UPGRADED to podman
83 - name: dummy
84 run: |
85 soil/github-actions.sh run-job dummy podman
86
87 - name: publish-html
88 env:
89 # for deploying to dashboard
90 TOIL_KEY: ${{ secrets.TOIL_KEY }}
91 run: |
92 soil/github-actions.sh publish-and-exit dummy T
93
94 dev-minimal:
95 # https://github.com/actions/virtual-environments
96 runs-on: ubuntu-22.04
97 env:
98 REPO_ROOT: ${{ github.workspace }}
99 steps:
100 - name: Check out repository code
101 uses: actions/checkout@v4
102
103 - name: dev-minimal
104 run: |
105 soil/github-actions.sh run-job dev-minimal
106
107 - name: publish-html
108 env:
109 # for deploying to dashboard
110 TOIL_KEY: ${{ secrets.TOIL_KEY }}
111 run: |
112 soil/github-actions.sh publish-and-exit dev-minimal T
113
114 interactive:
115 runs-on: ubuntu-22.04
116 env:
117 REPO_ROOT: ${{ github.workspace }}
118 steps:
119 - name: Check out repository code
120 uses: actions/checkout@v4
121
122 - name: Fix kernel mmap rnd bits
123 # Asan in llvm 14 provided in ubuntu 22.04 is incompatible with
124 # high-entropy ASLR in much newer kernels that GitHub runners are
125 # using leading to random crashes: https://reviews.llvm.org/D148280
126 run: sudo sysctl vm.mmap_rnd_bits=28
127
128 - name: interactive
129 run: |
130 soil/github-actions.sh run-job interactive
131
132 - name: publish-html
133 env:
134 # for deploying to dashboard
135 TOIL_KEY: ${{ secrets.TOIL_KEY }}
136 run: |
137 soil/github-actions.sh publish-and-exit interactive T
138
139 pea:
140 runs-on: ubuntu-22.04
141 env:
142 REPO_ROOT: ${{ github.workspace }}
143 steps:
144 - name: Check out repository code
145 uses: actions/checkout@v4
146
147 # UPGRADED to podman
148 - name: pea
149 run: |
150 soil/github-actions.sh run-job pea podman
151
152 - name: publish-html
153 env:
154 # for deploying to dashboard
155 TOIL_KEY: ${{ secrets.TOIL_KEY }}
156 run: |
157 soil/github-actions.sh publish-and-exit pea T
158
159 other-tests:
160 runs-on: ubuntu-22.04
161 env:
162 REPO_ROOT: ${{ github.workspace }}
163 steps:
164 - name: Check out repository code
165 uses: actions/checkout@v4
166
167 - name: other-tests
168 run: |
169 soil/github-actions.sh run-job other-tests
170
171 - name: publish-html
172 env:
173 # for deploying to dashboard
174 TOIL_KEY: ${{ secrets.TOIL_KEY }}
175 run: |
176 soil/github-actions.sh publish-and-exit other-tests T
177
178 ovm-tarball:
179 runs-on: ubuntu-22.04
180 env:
181 REPO_ROOT: ${{ github.workspace }}
182 steps:
183 - name: Check out repository code
184 uses: actions/checkout@v4
185
186 - name: ovm-tarball
187 run: |
188 soil/github-actions.sh run-job ovm-tarball
189
190 - name: publish-html
191 env:
192 # for deploying to dashboard
193 TOIL_KEY: ${{ secrets.TOIL_KEY }}
194 run: |
195 soil/github-actions.sh publish-and-exit ovm-tarball T
196
197 app-tests:
198 runs-on: ubuntu-22.04
199 env:
200 REPO_ROOT: ${{ github.workspace }}
201 needs: ['cpp-tarball']
202 steps:
203 - name: Check out repository code
204 uses: actions/checkout@v4
205
206 - name: app-tests
207 run: |
208 soil/github-actions.sh run-job app-tests
209
210 - name: publish-html
211 env:
212 # for deploying to dashboard
213 TOIL_KEY: ${{ secrets.TOIL_KEY }}
214 run: |
215 soil/github-actions.sh publish-and-exit app-tests T
216
217 cpp-coverage:
218 runs-on: ubuntu-22.04
219 env:
220 REPO_ROOT: ${{ github.workspace }}
221 steps:
222 - name: Check out repository code
223 uses: actions/checkout@v4
224
225 - name: cpp-coverage
226 run: |
227 soil/github-actions.sh run-job cpp-coverage
228
229 - name: publish-html
230 env:
231 # for deploying to dashboard
232 TOIL_KEY: ${{ secrets.TOIL_KEY }}
233 run: |
234 soil/github-actions.sh publish-and-exit cpp-coverage T
235
236 benchmarks:
237 runs-on: ubuntu-22.04
238 env:
239 REPO_ROOT: ${{ github.workspace }}
240 steps:
241 - name: Check out repository code
242 uses: actions/checkout@v4
243
244 - name: benchmarks
245 run: |
246 soil/github-actions.sh run-job benchmarks
247
248 - name: publish-html
249 env:
250 # for deploying to dashboard
251 TOIL_KEY: ${{ secrets.TOIL_KEY }}
252 run: |
253 soil/github-actions.sh publish-and-exit benchmarks T
254
255 benchmarks2:
256 runs-on: ubuntu-22.04
257 env:
258 REPO_ROOT: ${{ github.workspace }}
259 steps:
260 - name: Check out repository code
261 uses: actions/checkout@v4
262
263 - name: benchmarks2
264 run: |
265 soil/github-actions.sh run-job benchmarks2
266
267 - name: publish-html
268 env:
269 # for deploying to dashboard
270 TOIL_KEY: ${{ secrets.TOIL_KEY }}
271 run: |
272 soil/github-actions.sh publish-and-exit benchmarks2 T
273
274 cpp-small:
275 runs-on: ubuntu-22.04
276 env:
277 REPO_ROOT: ${{ github.workspace }}
278 steps:
279 - name: Check out repository code
280 uses: actions/checkout@v4
281
282 - name: Fix kernel mmap rnd bits
283 # Asan in llvm 14 provided in ubuntu 22.04 is incompatible with
284 # high-entropy ASLR in much newer kernels that GitHub runners are
285 # using leading to random crashes: https://reviews.llvm.org/D148280
286 run: sudo sysctl vm.mmap_rnd_bits=28
287
288 - name: cpp-small
289 run: |
290 soil/github-actions.sh run-job cpp-small
291
292 - name: publish-html
293 env:
294 # for deploying to dashboard
295 TOIL_KEY: ${{ secrets.TOIL_KEY }}
296 run: |
297 soil/github-actions.sh publish-and-exit cpp-small T
298
299 cpp-tarball:
300 runs-on: ubuntu-22.04
301 env:
302 REPO_ROOT: ${{ github.workspace }}
303 steps:
304 - name: Check out repository code
305 uses: actions/checkout@v4
306
307 - name: Fix kernel mmap rnd bits
308 # Asan in llvm 14 provided in ubuntu 22.04 is incompatible with
309 # high-entropy ASLR in much newer kernels that GitHub runners are
310 # using leading to random crashes: https://reviews.llvm.org/D148280
311 run: sudo sysctl vm.mmap_rnd_bits=28
312
313 - name: cpp-tarball
314 run: |
315 soil/github-actions.sh run-job cpp-tarball
316
317 # can't be done inside container
318 - name: publish-cpp-tarball
319 env:
320 # auth for web server
321 TOIL_KEY: ${{ secrets.TOIL_KEY }}
322 run: |
323 soil/github-actions.sh publish-cpp-tarball
324
325 - name: publish-html
326 env:
327 TOIL_KEY: ${{ secrets.TOIL_KEY }}
328 run: |
329 soil/github-actions.sh publish-and-exit cpp-tarball T
330
331 cpp-spec:
332 runs-on: ubuntu-22.04
333 env:
334 REPO_ROOT: ${{ github.workspace }}
335 steps:
336 - name: Check out repository code
337 uses: actions/checkout@v4
338
339 - name: Fix kernel mmap rnd bits
340 # Asan in llvm 14 provided in ubuntu 22.04 is incompatible with
341 # high-entropy ASLR in much newer kernels that GitHub runners are
342 # using leading to random crashes: https://reviews.llvm.org/D148280
343 run: sudo sysctl vm.mmap_rnd_bits=28
344
345 - name: cpp-spec
346 run: |
347 soil/github-actions.sh run-job cpp-spec
348
349 - name: publish-html
350 env:
351 # for deploying to dashboard
352 TOIL_KEY: ${{ secrets.TOIL_KEY }}
353 run: |
354 soil/github-actions.sh publish-and-exit cpp-spec T
355
356 wild:
357 runs-on: ubuntu-22.04
358 env:
359 REPO_ROOT: ${{ github.workspace }}
360 needs: ['cpp-tarball']
361 steps:
362 - name: Check out repository code
363 uses: actions/checkout@v4
364
365 - name: wild
366 run: |
367 soil/github-actions.sh run-job wild
368
369 - name: publish-html
370 env:
371 # for deploying to dashboard
372 TOIL_KEY: ${{ secrets.TOIL_KEY }}
373 run: |
374 soil/github-actions.sh publish-and-exit wild T
375
376 maybe-merge-to-master:
377 runs-on: ubuntu-22.04
378 env:
379 REPO_ROOT: ${{ github.workspace }}
380 # List of tasks to wait on. Copied from soil/worker.sh list-jobs
381 needs: ['dummy', 'benchmarks', 'benchmarks2', 'dev-minimal', 'cpp-coverage', 'cpp-small', 'cpp-spec', 'cpp-tarball', 'interactive', 'ovm-tarball', 'pea', 'other-tests', 'app-tests', 'wild', 'raw-vm', 'dev-setup-debian']
382 #needs: ['dummy', 'pea', 'other-tests']
383 steps:
384 - name: Check out repository code
385 uses: actions/checkout@v4
386
387 - name: maybe-merge
388 env:
389 SOIL_GITHUB_API_TOKEN: ${{ secrets.SOIL_GITHUB_API_TOKEN }}
390 run: |
391 soil/worker.sh JOB-maybe-merge
392
393 - name: publish-html
394 env:
395 # for deploying to dashboard
396 TOIL_KEY: ${{ secrets.TOIL_KEY }}
397 run: |
398 # NOTE: does not publish to status API
399 soil/github-actions.sh publish-and-exit maybe-merge