Skip to content

Modern Docker Management, Designed for Everyone

chore: fix pnpm cache

Kyle Mendell54d67eb57204
diff --git a/docker/Dockerfile b/docker/Dockerfile
index 15c1b5108..6c1e6fb2f 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -13,13 +13,11 @@ COPY pnpm-lock.yaml pnpm-workspace.yaml package.json ./
COPY frontend/package.json ./frontend/package.json
RUN --mount=type=cache,id=arcane-pnpm-v2,target=/pnpm/store,sharing=locked \
- pnpm fetch
+ pnpm fetch && \
+ pnpm install -r --offline --frozen-lockfile
COPY frontend ./frontend
-RUN --mount=type=cache,id=arcane-pnpm-v2,target=/pnpm/store,sharing=locked \
- pnpm install -r --offline --frozen-lockfile
-
ENV BUILD_PATH=dist
ENV NODE_OPTIONS="--max-old-space-size=4096"
RUN pnpm -C frontend build
diff --git a/docker/Dockerfile.dev b/docker/Dockerfile.dev
index 354c2317c..b57ddc536 100644
--- a/docker/Dockerfile.dev
+++ b/docker/Dockerfile.dev
@@ -17,15 +17,12 @@ COPY frontend/package.json ./frontend/package.json
# Fetch dependencies with cache mount
RUN --mount=type=cache,id=arcane-pnpm-v2,target=/pnpm/store,sharing=locked \
- pnpm fetch
+ pnpm fetch && \
+ pnpm install -r --offline --frozen-lockfile
# Copy frontend source
COPY frontend ./frontend
-# Install from the store (offline)
-RUN --mount=type=cache,id=arcane-pnpm-v2,target=/pnpm/store,sharing=locked \
- pnpm install -r --offline --frozen-lockfile
-
ENV NODE_ENV=development \
PORT=3000