diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bb7bd3b8..cb00d9ea 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,7 +53,7 @@ jobs: changes: name: Select checks - runs-on: ubuntu-24.04 + runs-on: ${{ github.event_name == 'pull_request' && 'ubuntu-24.04' || 'self-hosted-fast' }} outputs: native: ${{ steps.paths.outputs.native }} kernel: ${{ steps.paths.outputs.kernel }} @@ -105,7 +105,7 @@ jobs: checks: name: Format and repository checks - runs-on: ubuntu-24.04 + runs-on: ${{ github.event_name == 'pull_request' && 'ubuntu-24.04' || 'self-hosted-fast' }} timeout-minutes: 15 steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 @@ -209,7 +209,7 @@ jobs: tests: name: Native Linux tests (${{ matrix.shard }}/4) needs: [changes, build-tests] - runs-on: ubuntu-24.04 + runs-on: ${{ github.event_name == 'pull_request' && 'ubuntu-24.04' || 'self-hosted-fast' }} timeout-minutes: 60 strategy: fail-fast: false @@ -224,6 +224,8 @@ jobs: steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: Install a software Vulkan driver (lavapipe) + # Preinstalled on the self-hosted runner, which has no sudo. + if: runner.environment == 'github-hosted' run: | sudo apt-get update sudo apt-get install -y --no-install-recommends mesa-vulkan-drivers libvulkan1 @@ -391,7 +393,7 @@ jobs: name: Reference tests needs: changes if: needs.changes.outputs.native == 'true' - runs-on: ubuntu-24.04 + runs-on: ${{ github.event_name == 'pull_request' && 'ubuntu-24.04' || 'self-hosted-fast' }} timeout-minutes: 60 env: CARGO_INCREMENTAL: "0" @@ -478,7 +480,7 @@ jobs: ci: needs: [changes, checks, clippy, build-tests, tests, doc-tests, oracle, windows-fxc, windows-startup] if: always() - runs-on: ubuntu-24.04 + runs-on: ${{ github.event_name == 'pull_request' && 'ubuntu-24.04' || 'self-hosted-fast' }} steps: - name: Verify required checks env: