Prepare release v5.7.16 #2995
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: ["main"] | |
| pull_request: | |
| permissions: | |
| contents: read | |
| jobs: | |
| rust-lint: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - name: Update Rust toolchain | |
| run: rustup update | |
| - name: Rust Cache | |
| uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2.9.2 | |
| - name: Clippy | |
| run: cargo clippy --all-targets --workspace --locked -- --deny warnings | |
| - name: rustfmt | |
| run: cargo fmt -- --check | |
| rust-unit-test: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - name: Update Rust toolchain | |
| run: rustup update | |
| - name: Rust Cache | |
| uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2.9.2 | |
| - name: Run unit tests | |
| run: cargo test --locked | |
| # Currently a separate job since the #coverage(off) attribute requires nightly Rust. As soon as we can use llvm-cov | |
| # without Rust nightly, we should merge this job with the regular unit tests. | |
| unit-test-coverage: | |
| name: Generate test coverage report | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| submodules: true | |
| - name: Install nightly Rust toolchain | |
| run: rustup install nightly | |
| - name: Rust Cache | |
| uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2.9.2 | |
| - name: Install cargo-llvm-cov | |
| uses: taiki-e/install-action@5bf6ce016fd2e72eefc647cbca1e4213f65955b8 # v2.87.5 | |
| with: | |
| tool: cargo-llvm-cov | |
| - name: Run unit tests and generate coverage report | |
| run: cargo +nightly llvm-cov --locked --html | |
| - name: Upload HTML coverage report | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: "llvm-cov-html-${{github.event.repository.name}}-${{github.sha}}" | |
| path: "target/llvm-cov/html" | |
| if-no-files-found: "error" | |
| rust-integration-test: | |
| name: Integration (${{ matrix.builder }}, ${{ matrix.arch }}) | |
| runs-on: ${{ matrix.arch == 'arm64' && 'ubuntu-24.04-arm' || 'ubuntu-24.04' }} | |
| env: | |
| INTEGRATION_TEST_CNB_BUILDER: heroku/${{ matrix.builder }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| builder: ["builder:26", "builder:24", "builder:22"] | |
| arch: ["amd64", "arm64"] | |
| exclude: | |
| - builder: "builder:22" | |
| arch: "arm64" | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - name: Disable containerd snapshotter feature | |
| run: | | |
| docker info -f '{{ .DriverStatus }}' | |
| sudo systemctl stop docker | |
| echo '{"features": {"containerd-snapshotter": false}}' | sudo tee /etc/docker/daemon.json | |
| sudo systemctl start docker | |
| docker info -f '{{ .DriverStatus }}' | |
| # The dpkg man-db trigger is excessively slow on GHA runners, see e.g.: | |
| # https://github.com/actions/runner-images/issues/10977 | |
| # https://github.com/actions/runner/issues/4030 | |
| # We disable it here so it does not fire at the end of the following apt-get install | |
| - name: Disable man-db auto-update | |
| run: sudo rm -f /var/lib/man-db/auto-update | |
| - name: Install musl-tools | |
| run: sudo apt-get install musl-tools -y --no-install-recommends | |
| - name: Update Rust toolchain | |
| run: rustup update | |
| - name: Install Rust linux-musl target | |
| run: rustup target add ${{ matrix.arch == 'arm64' && 'aarch64-unknown-linux-musl' || 'x86_64-unknown-linux-musl' }} | |
| - name: Rust Cache | |
| uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2.9.2 | |
| - name: Install Pack CLI | |
| uses: buildpacks/github-actions/setup-pack@af8c06ccd592e27001cbf78083dcc9b47aa6652a # v6.1.1 | |
| - name: Install Nextest | |
| uses: taiki-e/install-action@5bf6ce016fd2e72eefc647cbca1e4213f65955b8 # v2.87.5 | |
| with: | |
| tool: nextest | |
| - name: Pull builder image | |
| run: docker pull ${{ env.INTEGRATION_TEST_CNB_BUILDER }} | |
| - name: Pull run image | |
| run: | | |
| RUN_IMAGE=$( | |
| docker inspect --format='{{index .Config.Labels "io.buildpacks.builder.metadata"}}' '${{ env.INTEGRATION_TEST_CNB_BUILDER }}' \ | |
| | jq --exit-status --raw-output '.stack.runImage.image' | |
| ) | |
| docker pull "${RUN_IMAGE}" | |
| - name: Run integration tests | |
| run: cargo nextest run --run-ignored only --locked |