Skip to content

Commit c5ca451

Browse files
committed
Fixup cache key for GA: prefer matrix.os
Change-Id: I43684ca1900c41934a244e2be810f7358419d07e
1 parent 449528d commit c5ca451

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

.github/workflows/pr.yaml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,15 @@ on: [push, pull_request]
1212

1313
jobs:
1414
testing:
15-
runs-on: ubuntu-24.04
15+
runs-on: ${{ matrix.os }}
1616
env:
1717
PYTHONWARNINGS: ignore:DeprecationWarning
1818
# Avoid falling back to our internal bazel remote cache on github actions
1919
BAZEL_CACHE_URL: ""
2020
# Needed by "make .venv" to compute PYTHON_REQUIREMENTS_TEST
2121
EDITION: community
2222
strategy:
23+
os: [ubuntu-24.04]
2324
matrix:
2425
include:
2526
- name: Bandit tests
@@ -68,7 +69,7 @@ jobs:
6869
- name: Cache uv
6970
uses: actions/cache@v3
7071
with:
71-
key: uv-$ImageOS-${{ hashFiles('requirements_all_lock.txt') }}
72+
key: uv-${{ matrix.os }}-${{ hashFiles('requirements_all_lock.txt') }}
7273
path: ${{ env.UV_CACHE_DIR }}
7374
- name: Cache bazelisk
7475
uses: actions/cache@v3
@@ -79,11 +80,11 @@ jobs:
7980
- name: Cache bazel
8081
uses: actions/cache@v3
8182
with:
82-
key: $ImageOS-bazel-${{ hashFiles('.bazelversion', '.bazelrc', 'WORKSPACE', 'MODULE.bazel') }}
83+
key: ${{ matrix.os }}-bazel-${{ hashFiles('.bazelversion', '.bazelrc', 'WORKSPACE', 'MODULE.bazel') }}
8384
path: |
8485
~/.cache/bazel
8586
restore-keys: |
86-
$ImageOS-bazel-
87+
${{ matrix.os }}-bazel-
8788
- name: Setup Environment
8889
run: |
8990
# ksh: Needed for some "unit test" (test_mk_errpt_aix).

0 commit comments

Comments
 (0)