8
8
RUSTFLAGS : " -Dwarnings"
9
9
10
10
jobs :
11
- fmt :
12
- name : Code Formatting Check
13
- runs-on : ubuntu-latest
14
- steps :
15
- - uses : actions/checkout@v4
16
-
17
- with :
18
- components : rustfmt
19
- - uses : Swatinem/rust-cache@v2
20
- - name : " rustfmt --check"
21
- run : |
22
- if ! rustfmt --check --edition 2024 $(git ls-files '*.rs'); then
23
- printf "Please run \`rustfmt --edition 2024 \$(git ls-files '*.rs')\` to fix rustfmt errors.\nSee CONTRIBUTING.md for more details.\n" >&2
24
- exit 1
25
- fi
11
+ # fmt:
12
+ # name: Code Formatting Check
13
+ # runs-on: ubuntu-latest
14
+ # steps:
15
+ # - uses: actions/checkout@v4
16
+ # - uses: dtolnay/[email protected]
17
+ # with:
18
+ # components: rustfmt
19
+ # - uses: Swatinem/rust-cache@v2
20
+ # - name: "rustfmt --check"
21
+ # run: |
22
+ # if ! rustfmt --check --edition 2024 $(git ls-files '*.rs'); then
23
+ # printf "Please run \`rustfmt --edition 2024 \$(git ls-files '*.rs')\` to fix rustfmt errors.\nSee CONTRIBUTING.md for more details.\n" >&2
24
+ # exit 1
25
+ # fi
26
26
27
- clippy_check :
28
- name : Linter Check
29
- runs-on : ubuntu-latest
30
- steps :
31
- - uses : actions/checkout@v4
32
-
33
- with :
34
- components : clippy
35
- - name : Install Protocol Buffers Compiler
36
- run : sudo apt-get install -y protobuf-compiler
37
- - name : Set PROTOC Environment Variable
38
- run : export PROTOC=/path/to/protoc
39
- - name : Run Clippy
40
- run : cargo clippy
41
- - name : Run Clippy
42
- run : cargo clippy --package holo-tools
27
+ # clippy_check:
28
+ # name: Linter Check
29
+ # runs-on: ubuntu-latest
30
+ # steps:
31
+ # - uses: actions/checkout@v4
32
+ # - uses: dtolnay/[email protected]
33
+ # with:
34
+ # components: clippy
35
+ # - name: Install Protocol Buffers Compiler
36
+ # run: sudo apt-get install -y protobuf-compiler
37
+ # - name: Set PROTOC Environment Variable
38
+ # run: export PROTOC=/path/to/protoc
39
+ # - name: Run Clippy
40
+ # run: cargo clippy
41
+ # - name: Run Clippy
42
+ # run: cargo clippy --package holo-tools
43
43
44
- tests_and_coverage_report :
45
- name : Tests and Coverage Report
46
- runs-on : ubuntu-latest
47
- steps :
48
- - uses : actions/checkout@v4
49
-
50
- - name : Install cargo-llvm-cov
51
- uses : taiki-e/install-action@cargo-llvm-cov
52
- - name : Generate code coverage
53
- run : cargo llvm-cov --all-features --codecov --output-path codecov.json -p holo-bfd -p holo-bgp -p holo-isis -p holo-ldp -p holo-ospf -p holo-rip -p holo-vrrp
54
- - name : Upload to Codecov
55
- uses : codecov/codecov-action@v4
56
- if : github.event_name != 'pull_request'
57
- with :
58
- files : ./lcov.info
59
- fail_ci_if_error : false
60
- token : ${{ secrets.CODECOV_TOKEN }}
44
+ # tests_and_coverage_report:
45
+ # name: Tests and Coverage Report
46
+ # runs-on: ubuntu-latest
47
+ # steps:
48
+ # - uses: actions/checkout@v4
49
+ # - uses: dtolnay/[email protected]
50
+ # - name: Install cargo-llvm-cov
51
+ # uses: taiki-e/install-action@cargo-llvm-cov
52
+ # - name: Generate code coverage
53
+ # run: cargo llvm-cov --all-features --codecov --output-path codecov.json -p holo-bfd -p holo-bgp -p holo-isis -p holo-ldp -p holo-ospf -p holo-rip -p holo-vrrp
54
+ # - name: Upload to Codecov
55
+ # uses: codecov/codecov-action@v4
56
+ # if: github.event_name != 'pull_request'
57
+ # with:
58
+ # files: ./lcov.info
59
+ # fail_ci_if_error: false
60
+ # token: ${{ secrets.CODECOV_TOKEN }}
61
61
62
- tests_arm :
63
- name : Tests (Arm64)
64
- runs-on : ubuntu-24.04-arm
65
- steps :
66
- - uses : actions/checkout@v4
67
-
68
- - name : Run tests
69
- run : cargo test --all-features -p holo-bfd -p holo-bgp -p holo-isis -p holo-ldp -p holo-ospf -p holo-rip -p holo-vrrp
62
+ # tests_arm:
63
+ # name: Tests (Arm64)
64
+ # runs-on: ubuntu-24.04-arm
65
+ # steps:
66
+ # - uses: actions/checkout@v4
67
+ # - uses: dtolnay/[email protected]
68
+ # - name: Run tests
69
+ # run: cargo test --all-features -p holo-bfd -p holo-bgp -p holo-isis -p holo-ldp -p holo-ospf -p holo-rip -p holo-vrrp
70
70
71
- fuzz-build-check :
72
- name : Check fuzz targets build
73
- runs-on : ubuntu-latest
74
- steps :
75
- - uses : actions/checkout@v4
76
- # cargo-fuzz requires nightly Rust due to LLVM sanitizer support
77
- - uses : dtolnay/rust-toolchain@nightly
78
- - name : Install cargo-fuzz
79
- run : cargo install cargo-fuzz
80
- - name : Check fuzz targets
81
- run : cargo fuzz check
71
+ # fuzz-build-check:
72
+ # name: Check fuzz targets build
73
+ # runs-on: ubuntu-latest
74
+ # steps:
75
+ # - uses: actions/checkout@v4
76
+ # # cargo-fuzz requires nightly Rust due to LLVM sanitizer support
77
+ # - uses: dtolnay/rust-toolchain@nightly
78
+ # - name: Install cargo-fuzz
79
+ # run: cargo install cargo-fuzz
80
+ # - name: Check fuzz targets
81
+ # run: cargo fuzz check
82
82
83
- bench-build-check :
84
- name : Check benchmark builds
85
- runs-on : ubuntu-latest
86
- steps :
87
- - uses : actions/checkout@v4
88
-
89
- - name : Check benchmark builds
90
- run : cargo bench --no-run -p holo-bgp -p holo-ldp -p holo-ospf
83
+ # bench-build-check:
84
+ # name: Check benchmark builds
85
+ # runs-on: ubuntu-latest
86
+ # steps:
87
+ # - uses: actions/checkout@v4
88
+ # - uses: dtolnay/[email protected]
89
+ # - name: Check benchmark builds
90
+ # run: cargo bench --no-run -p holo-bgp -p holo-ldp -p holo-ospf
91
91
92
92
push-image :
93
93
name : Docker Image Build
94
94
runs-on : ubuntu-latest
95
- if : github.ref == 'refs/heads/master' && github.repository_owner == 'holo-routing'
95
+ # if: github.ref == 'refs/heads/master' && github.repository_owner == 'holo-routing'
96
+ permissions :
97
+ id-token : write
98
+ attestations : write
99
+ packages : write
96
100
steps :
97
101
- uses : actions/checkout@v4
98
102
- uses : docker/login-action@v3
@@ -106,3 +110,13 @@ jobs:
106
110
docker push ghcr.io/holo-routing/holod:latest
107
111
docker build . -f docker/Dockerfile.holo-bundle --tag ghcr.io/holo-routing/holo-bundle:latest
108
112
docker push ghcr.io/holo-routing/holo-bundle:latest
113
+ - name : Attest holod image
114
+ uses : actions/attest-build-provenance@v2
115
+ with :
116
+ subject-name : ghcr.io/holo-routing/holod:latest
117
+ push-to-registry : true
118
+ - name : Attest holo-bundle image
119
+ uses : actions/attest-build-provenance@v2
120
+ with :
121
+ subject-name : ghcr.io/holo-routing/holo-bundle:latest
122
+ push-to-registry : true
0 commit comments