-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (41 loc) · 1.25 KB
/
build-shim.yml
File metadata and controls
48 lines (41 loc) · 1.25 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
name: Build Shim
on:
merge_group:
pull_request:
branches: ['main', 'release/**']
permissions:
contents: read
jobs:
build:
name: Build (${{ matrix.goos }}/${{ matrix.goarch }})
runs-on: ubuntu-latest
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
include:
- goos: darwin
goarch: arm64
- goos: darwin
goarch: amd64
- goos: linux
goarch: amd64
- goos: linux
goarch: arm64
- goos: windows
goarch: amd64
suffix: .exe
- goos: windows
goarch: arm64
suffix: .exe
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version-file: '.github/.tool-versions'
- name: Build shim
run: |
mkdir -p _output
GOOS=${{ matrix.goos }} GOARCH=${{ matrix.goarch }} go build -o _output/containerd-shim-nerdbox-v1${{ matrix.suffix }} -ldflags '-s -w' -tags 'no_grpc' ./cmd/containerd-shim-nerdbox-v1
- name: Verify binary
run: file _output/containerd-shim-nerdbox-v1${{ matrix.suffix }}