From 74a1ea8ae5acd0736cd3ac19141592229fb5f6a1 Mon Sep 17 00:00:00 2001 From: Richard Ramos Date: Fri, 28 Feb 2025 09:46:44 -0400 Subject: [PATCH] chore: fix ci --- .github/workflows/ci.yml | 8 ++++++++ tests/hole-punching-interop/Dockerfile | 4 ++++ tests/transport-interop/Dockerfile | 4 ++++ 3 files changed, 16 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e1a6c4fe42..1195c804be 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -96,9 +96,15 @@ jobs: # The change happened on Nimble v0.14.0. Also forcing the deps to be reinstalled on each os and cpu. key: nimbledeps-${{ matrix.nim.ref }}-${{ matrix.builder }}-${{ matrix.platform.cpu }}-${{ hashFiles('.pinned') }} # hashFiles returns a different value on windows + - name: Setup python + run: | + mkdir .venv + python -m venv .venv + - name: Install deps if: ${{ steps.deps-cache.outputs.cache-hit != 'true' }} run: | + source .venv/bin/activate nimble install_pinned - name: Use gcc 14 @@ -112,6 +118,8 @@ jobs: - name: Run tests run: | + source .venv/bin/activate + nim --version nimble --version gcc --version diff --git a/tests/hole-punching-interop/Dockerfile b/tests/hole-punching-interop/Dockerfile index f7dd1b0064..3f2030c93a 100644 --- a/tests/hole-punching-interop/Dockerfile +++ b/tests/hole-punching-interop/Dockerfile @@ -5,6 +5,10 @@ WORKDIR /workspace COPY .pinned libp2p.nimble nim-libp2p/ +RUN --mount=type=cache,target=/var/cache/apt apt-get update && apt-get install -y python python3 python3-pip python3-venv curl + +RUN mkdir .venv && python3 -m venv .venv && . .venv/bin/activate + RUN cd nim-libp2p && nimble install_pinned && nimble install redis -y COPY . nim-libp2p/ diff --git a/tests/transport-interop/Dockerfile b/tests/transport-interop/Dockerfile index e1aa31d390..7ab3a82abb 100644 --- a/tests/transport-interop/Dockerfile +++ b/tests/transport-interop/Dockerfile @@ -5,6 +5,10 @@ WORKDIR /app COPY .pinned libp2p.nimble nim-libp2p/ +RUN --mount=type=cache,target=/var/cache/apt apt-get update && apt-get install -y python python3 python3-pip python3-venv curl + +RUN mkdir .venv && python3 -m venv .venv && . .venv/bin/activate + RUN cd nim-libp2p && nimble install_pinned && nimble install "redis@#b341fe240dbf11c544011dd0e033d3c3acca56af" -y COPY . nim-libp2p/