-
Notifications
You must be signed in to change notification settings - Fork 85
55 lines (46 loc) · 1.49 KB
/
dep_fuzzing.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
name: Fuzzing Job
on:
workflow_call:
inputs:
max_total_time:
description: Maximum total time for the fuzz run in seconds
required: true
type: number
docs_only:
description: Skip fuzzing if docs only
required: false
type: string
default: "false"
permissions:
id-token: write
contents: read
jobs:
fuzz:
if: ${{ inputs.docs_only == 'false' }}
runs-on: [ self-hosted, Linux, X64, "1ES.Pool=hld-kvm-amd" ]
steps:
- name: Checkout code
uses: actions/checkout@v4
- uses: hyperlight-dev/[email protected]
with:
rust-toolchain: "1.81.0"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Set up nightly rust
uses: dtolnay/rust-toolchain@nightly
- name: Build rust binaries
run: |
# use these commands in favor of build-and-move-rust-guests to avoid building debug
just build-rust-guests release
just move-rust-guests release
- name: Install cargo-fuzz
run: cargo install cargo-fuzz
- name: Run Fuzzing
run: cargo +nightly fuzz run --release fuzz_target_1 -- -max_total_time=300
working-directory: src/hyperlight_host
- name: Upload Crash Artifacts
if: failure() # This ensures artifacts are only uploaded on failure
uses: actions/upload-artifact@v4
with:
name: fuzz-crash-artifacts
path: src/hyperlight_host/fuzz/artifacts/