github-actions: cache netmap checkout

To avoid build failures due to rate limiting, cache the netmap checkout.

Explicitly restore and save to avoid the checkout action cleaning the
checkout up before it can be stored in the cache.
pull/11949/head
Victor Julien 5 months ago committed by Victor Julien
parent 15c4eb3d16
commit 9b6a1355ac

@ -2374,6 +2374,13 @@ jobs:
needs: [prepare-deps, prepare-cbindgen]
runs-on: ubuntu-22.04
steps:
- name: Restore Cache Netmap
uses: actions/cache/restore@v4
id: netmap-cache
with:
path: netmap/
key: netmap-git
# Cache Rust stuff.
- name: Cache cargo registry
uses: actions/cache@13aacd865c20de90d75de3b17ebe84f7a17d57d2
@ -2429,12 +2436,20 @@ jobs:
linux-headers-$(uname -r)
- name: Checkout Netmap repository
if: steps.netmap-cache.outputs.cache-hit != 'true'
uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938
with:
repository: luigirizzo/netmap
# gets cloned to $GITHUB_WORKSPACE/netmap/
path: netmap/
- name: Save Netmap Cache
if: steps.netmap-cache.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: netmap/
key: netmap-git
- name: Compile and install Netmap
run: |
cd $GITHUB_WORKSPACE/netmap/LINUX

Loading…
Cancel
Save