-
Notifications
You must be signed in to change notification settings - Fork 82
81 lines (76 loc) · 2.3 KB
/
build.yml
File metadata and controls
81 lines (76 loc) · 2.3 KB
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
name: Build
on:
push:
branches: ['main', 'release/**']
paths:
- '**'
- '!docs/**' # ignore docs changes
- '!**.md' # ignore markdown changes
pull_request:
branches: ['main', 'release/**']
paths:
- '.github/workflows/build.yml'
- '**.go'
- 'go.*'
- 'cmd/go.*'
- 'Makefile'
- 'Dockerfile'
- 'integration/**'
- 'scripts/**'
- 'ztoc/**' # Includes flatbuf + C files
- '!benchmark/**'
env:
GOTESTSUM_VERSION: 1.13.0
jobs:
setup:
uses: ./.github/workflows/setup.yml
test:
needs: setup
runs-on: ${{ fromJSON(needs.setup.outputs.runner-labels)[matrix.os] }}
strategy:
matrix:
os: ${{ fromJSON(needs.setup.outputs.available-runners) }}
go-version: ['1.25.7', '1.26.0']
timeout-minutes: 15
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: ${{ matrix.go-version }}
- name: Install zlib static on AL2 ARM instances
if: matrix.os == 'al2-arm'
run: dnf install zlib-static.aarch64 -y
- run: make
- run: make test-with-coverage
- name: Show test coverage
run: make show-test-coverage
integration:
needs: setup
runs-on: ${{ fromJSON(needs.setup.outputs.runner-labels)[matrix.os] }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
os: ${{ fromJSON(needs.setup.outputs.available-runners) }}
go-version: ['1.25.7', '1.26.0']
containerd: ["1.7.29", "2.0.7", "2.1.5"]
env:
DOCKER_BUILD_ARGS: "CONTAINERD_VERSION=${{ matrix.containerd }}"
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: ${{ matrix.go-version }}
- name: Install gotestsum
run: go install gotest.tools/gotestsum@v${{ env.GOTESTSUM_VERSION }}
- name: Install zlib static on AL2 ARM instances
if: matrix.os == 'al2-arm'
run: dnf install zlib-static.aarch64 -y
- name: Run integration tests
run: |
if [[ "${{ matrix.os }}" == "ubuntu-x86" ]]; then
SKIP_SYSTEMD_TESTS=1
fi
SKIP_SYSTEMD_TESTS=$SKIP_SYSTEMD_TESTS make integration-with-coverage
- name: Show test coverage
run: make show-integration-coverage