-
Notifications
You must be signed in to change notification settings - Fork 12
130 lines (110 loc) · 3.86 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
name: CI
on:
push:
branches:
- "main"
pull_request:
schedule:
- cron: '0 12 * * *' # daily at 12:00 UTC
# Cancel pending jobs on push.
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-using-concurrency-to-cancel-any-in-progress-job-or-run
concurrency:
group: ${{ github.workflow }}.${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
# Recommended here: https://github.com/bazelbuild/bazelisk/issues/88#issuecomment-625178467
env:
BAZELISK_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
OPAL_RPC_CREDENTIALS: ${{ secrets.OPAL_RPC_CREDENTIALS }}
jobs:
test-matrix:
runs-on:
- self-hosted
- "os=${{ matrix.os }}"
- "arch=${{ matrix.arch }}"
- "os_distribution=${{ matrix.os_distribution }}"
- "os_version=${{ matrix.os_version }}"
- "revision=${{ matrix.revision }}"
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
include:
- os: macos
arch: x64
os_distribution: monterey
os_version: "12"
revision: d04e89854b3931f4aaced77aa3a2fcad5834b3a6
remote_execution: 'false'
- os: macos
arch: x64
os_distribution: monterey
os_version: "12"
revision: d04e89854b3931f4aaced77aa3a2fcad5834b3a6
remote_execution: 'true'
steps:
- uses: actions/checkout@v4
- name: Set up authentication
shell: bash
run: cp infra/bazelrc .bazelrc.user
- name: Generate python requirements lock
shell: bash
run: bazel run //python:requirements.update
- name: Build and test
env:
ARCH: ${{ matrix.arch }}
OS: ${{ matrix.os }}
REMOTE_EXECUTION: ${{ matrix.remote_execution }}
run: python3 infra/test-all.py
ci-runners-test-matrix:
runs-on:
- self-hosted
- "os=linux"
- "arch=x64"
- "remote_execution=${{ matrix.remote_execution }}"
- "engflow-container-image=docker://645088952840.dkr.ecr.eu-west-1.amazonaws.com/engflow-ci/debian11-dind-x64@sha256:604855f1ecd6edad3f45f513ed0112b9e8e32589871133767a1a51944b07f487"
- "engflow-pool=ci_sysbox_x64"
- "engflow-runtime=sysbox-runc"
- "engflow-runner-id=${{ github.repository_id }}_ci-runners-test-matrix_${{ github.run_id }}_${{ github.run_number }}_${{ github.run_attempt }}"
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
include:
- remote_execution: 'false'
- remote_execution: 'true'
steps:
- uses: actions/checkout@v3
- name: Set up authentication
shell: bash
run: cp infra/bazelrc .bazelrc.user
- name: Generate python requirements lock
shell: bash
run: bazel run //python:requirements.update
- name: Build and test
env:
ARCH: x64
OS: linux
REMOTE_EXECUTION: ${{ matrix.remote_execution }}
run: python3 infra/test-all.py
buck2-test:
runs-on:
- self-hosted
- "os=linux"
- "arch=x64"
- "engflow-container-image=docker://645088952840.dkr.ecr.eu-west-1.amazonaws.com/engflow-ci/debian12-dind-x64@sha256:763903935682de148b4e09fe1d7ef3bbc4ec829d59c3f41cb9519984639eaa06"
- "engflow-pool=ci_sysbox_x64"
- "engflow-runtime=sysbox-runc"
- "engflow-runner-id=${{ github.repository_id }}_buck2-test_${{ github.run_id }}_${{ github.run_number }}_${{ github.run_attempt }}"
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- name: Set up Buck2 binary
shell: bash
run: infra/setup-buck2.sh
- name: Set up authentication
shell: bash
run: infra/auth-buck2.sh
- name: Build and test
shell: bash
run: infra/test-buck2.sh