|
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 |
| - push-image: |
93 |
| - name: Docker Image Build |
94 |
| - runs-on: ubuntu-latest |
95 |
| - if: github.ref == 'refs/heads/master' && github.repository_owner == 'holo-routing' |
96 |
| - steps: |
97 |
| - - uses: actions/checkout@v4 |
98 |
| - - uses: docker/login-action@v3 |
99 |
| - with: |
100 |
| - registry: ghcr.io |
101 |
| - username: ${{github.actor}} |
102 |
| - password: ${{secrets.GITHUB_TOKEN}} |
103 |
| - - name: Build and push container image |
104 |
| - run: | |
105 |
| - docker build . -f docker/Dockerfile.holod --tag ghcr.io/holo-routing/holod:latest |
106 |
| - docker push ghcr.io/holo-routing/holod:latest |
107 |
| - docker build . -f docker/Dockerfile.holo-bundle --tag ghcr.io/holo-routing/holo-bundle:latest |
108 |
| - docker push ghcr.io/holo-routing/holo-bundle:latest |
| 92 | + docker-build-holod: |
| 93 | + uses: .github/workflows/build-and-attest.yml |
| 94 | + with: |
| 95 | + image-name: holod |
| 96 | + dockerfile: docker/Dockerfile.holod |
| 97 | + permissions: |
| 98 | + id-token: write |
| 99 | + attestations: write |
| 100 | + packages: write |
| 101 | + |
| 102 | + docker-build-holo-bundle: |
| 103 | + needs: docker-build-holod |
| 104 | + uses: .github/workflows/build-and-attest.yml |
| 105 | + with: |
| 106 | + image-name: holo-bundle |
| 107 | + dockerfile: docker/Dockerfile.holo-bundle |
| 108 | + permissions: |
| 109 | + id-token: write |
| 110 | + attestations: write |
| 111 | + packages: write |
0 commit comments