-
Notifications
You must be signed in to change notification settings - Fork 10
42 lines (36 loc) · 1.04 KB
/
buildtest.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
name: Go-build-and-test
on:
push:
pull_request:
schedule:
- cron: "0 8 * * 0" # every sunday
permissions:
contents: read
jobs:
build-test:
strategy:
matrix:
go-version: [1.21.x]
os: [ubuntu-latest]
subproject: [ipu-plugin, ipu-device-plugin] # Add more subprojects as needed
runs-on: ${{ matrix.os }}
env:
GO111MODULE: on
steps:
- name: Harden Runner
uses: step-security/harden-runner@63c24ba6bd7ba022e95695ff85de572c04a18142 # v2.7.0
with:
egress-policy: audit
- name: Set up Go
uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
with:
go-version: ${{ matrix.go-version }}
- name: Check out code into the Go module directory
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: Build each subproject
run: |
for subproject in ${{ matrix.subproject }}; do
cd "$subproject"
make build
cd ..
done