test: debug #8
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: Integration CI | |
| on: | |
| workflow_call: | |
| push: | |
| branches: | |
| - gha-runners | |
| env: | |
| CARGO_TERM_COLOR: always | |
| CARGO_INCREMENTAL: 0 | |
| CI: 1 | |
| jobs: | |
| int-tests: | |
| #runs-on: oracle-vm-16cpu-64gb-x86-64 | |
| #runs-on: ubuntu-latest-16-cores | |
| runs-on: oracle-vm-16cpu-64gb-x86-64 | |
| permissions: | |
| contents: read | |
| id-token: write | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| submodules: 'recursive' | |
| - uses: cachix/[email protected] | |
| with: | |
| github_access_token: '' | |
| - name: Inject github token to nix config | |
| run: | | |
| cat <<EOF | sudo tee -a /etc/nix/nix.conf | |
| access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
| trusted-users = root runner | |
| EOF | |
| - name: Restart Nix daemon | |
| run: sudo systemctl restart nix-daemon | |
| - uses: cachix/[email protected] | |
| - name: Pre-populate nix-shell | |
| run: | | |
| export NIX_PATH=nixpkgs=$(jq '.nixpkgs.url' nix/sources.json -r) | |
| echo "NIX_PATH=$NIX_PATH" >> $GITHUB_ENV | |
| nix-shell --run "echo" shell.nix | |
| - name: Handle Rust dependencies caching | |
| uses: Swatinem/rust-cache@v2 | |
| with: | |
| save-if: ${{ startsWith(github.ref_name, 'release/') || github.ref_name == 'develop' }} | |
| - name: Build binaries | |
| run: nix-shell --run "cargo build --bins --features=io-engine-testing" | |
| - name: Setup Test Pre-Requisites | |
| run: | | |
| sudo sysctl -w vm.nr_hugepages=3584 | |
| sudo debconf-communicate <<< "set man-db/auto-update false" || true | |
| sudo dpkg-reconfigure man-db || true | |
| ulimit -c unlimited | |
| sudo apt-get update | |
| sudo apt-get install linux-modules-extra-$(uname -r) | |
| for module in nvme_tcp nbd nvme_rdma; do | |
| sudo modprobe $module | |
| done | |
| sudo apt-get install gdb | |
| # Add debug info | |
| lsblk | |
| df -h | |
| mount | |
| - name: Run Rust Tests | |
| run: | | |
| echo "TEST_START_DATE=$(date +"%Y-%m-%d %H:%M:%S")" >> $GITHUB_ENV | |
| nix-shell --run "./scripts/cargo-test.sh" | |
| - name: Check Coredumps | |
| run: sudo ./scripts/check-coredumps.sh --since "${TEST_START_DATE}" | |
| - name: Cleanup | |
| if: always() | |
| run: nix-shell --run "./scripts/clean-cargo-tests.sh" | |
| - name: Run JS Grpc Tests | |
| run: | | |
| echo "TEST_START_DATE=$(date +"%Y-%m-%d %H:%M:%S")" >> $GITHUB_ENV | |
| nix-shell --run "./scripts/grpc-test.sh" | |
| mkdir -p ci-report/js | |
| for file in *-xunit-report.xml; do | |
| echo "<testsuites>" > "ci-report/js/$file" | |
| cat $file >> "ci-report/js/$file" | |
| echo "</testsuites>" >> "ci-report/js/$file" | |
| done | |
| - name: Test Report | |
| if: always() | |
| uses: pmeier/pytest-results-action@main | |
| with: | |
| path: 'ci-report/js/*-xunit-report.xml' | |
| summary: true | |
| display-options: a | |
| fail-on-empty: true | |
| title: Test results | |
| - run: nix-shell --run "./scripts/ci-report.sh" | |
| if: failure() | |
| - uses: actions/upload-artifact@v4 | |
| if: failure() | |
| with: | |
| name: ci-report-int | |
| path: ./ci-report/ci-report.tar.gz | |
| - name: Check Coredumps | |
| run: sudo ./scripts/check-coredumps.sh --since "${TEST_START_DATE}" | |
| - name: Cleanup | |
| if: always() | |
| run: nix-shell --run "./scripts/clean-cargo-tests.sh" | |
| # debugging | |
| # - name: Setup tmate session | |
| # if: ${{ failure() }} | |
| # timeout-minutes: 240 | |
| # uses: mxschmitt/action-tmate@v3 |