forked from microsoft/retina
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (43 loc) · 1.19 KB
/
Copy pathtest-ebpf.yaml
File metadata and controls
49 lines (43 loc) · 1.19 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
name: eBPF Program Tests
on:
push:
branches: [main]
paths:
- 'pkg/plugin/**/_cprog/**'
- 'pkg/plugin/**/*_ebpf_test.go'
- 'pkg/plugin/ebpftest/**'
pull_request:
branches: [main]
paths:
- 'pkg/plugin/**/_cprog/**'
- 'pkg/plugin/**/*_ebpf_test.go'
- 'pkg/plugin/ebpftest/**'
workflow_dispatch:
permissions:
contents: read
jobs:
ebpf-tests:
strategy:
matrix:
include:
- arch: amd64
runner: ubuntu-latest
- arch: arm64
runner: ubuntu-24.04-arm
runs-on: ${{ matrix.runner }}
steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version-file: go.mod
- name: Install clang and llvm-strip
run: |
sudo apt-get update
sudo apt-get install -y clang llvm
- name: Compile eBPF programs
run: |
GOARCH=${{ matrix.arch }} go generate ./pkg/plugin/...
- name: Run eBPF program tests
run: |
sudo $(which go) test -tags=ebpf -v -count=1 ./pkg/plugin/...