Skip to content

Add safe request timeout for running actions manager #1446

Add safe request timeout for running actions manager

Add safe request timeout for running actions manager #1446

Workflow file for this run

---
name: Nix
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions: read-all
jobs:
nix-bazel:
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04]
name: Bazel Dev / ${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: >- # v4.1.1
actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Install Nix
uses: >- # v9
DeterminateSystems/nix-installer-action@cd46bde16ab981b0a7b2dce0574509104543276e
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
nix-installer-tag: v0.16.1
- name: Cache Nix derivations
uses: >- # Custom commit, last pinned at 2024-03-03.
DeterminateSystems/magic-nix-cache-action@742d8701e54851d2136f71b61d31382a4f4d0788
# TODO(aaronmondal): Figure out why this cache breaks CI.
# See: https://github.com/TraceMachina/nativelink/issues/772
# - name: Mount bazel cache
# uses: >- # v4.0.1
# actions/cache@ab5e6d0c87105b4c9c2047343972218f562e4319
# with:
# path: "~/.cache/bazel"
# key: ${{ runner.os }}-bazel-nix
- name: Invoke Bazel build in Nix shell
run: |
if [ "$RUNNER_OS" == "Linux" ]; then
nix develop --impure --command \
bash -c "bazel test --config=linux_zig ... --verbose_failures"
elif [ "$RUNNER_OS" == "macOS" ]; then
nix develop --impure --command \
bash -c "bazel test //... --verbose_failures"
else
echo "Unsupported runner OS: $RUNNER_OS"
exit 1
fi
shell: bash
nix-cargo:
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04, macos-13]
name: Cargo Dev / ${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: >- # v4.1.1
actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Install Nix
uses: >- # v9
DeterminateSystems/nix-installer-action@cd46bde16ab981b0a7b2dce0574509104543276e
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
nix-installer-tag: v0.16.1
- name: Cache Nix derivations
uses: >- # Custom commit, last pinned at 2024-03-03.
DeterminateSystems/magic-nix-cache-action@742d8701e54851d2136f71b61d31382a4f4d0788
- name: Invoke Cargo build in Nix shell
run: >
nix develop --impure --command
bash -c "cargo test --all --profile=smol"