Skip to content

Commit a0c7d88

Browse files
committed
Fix Docker build: skip scripts in prod-deps stage
The prepare script runs husky which is a devDependency — not available when installing with --omit=dev. Adding --ignore-scripts skips lifecycle scripts that aren't needed for the production runtime dependencies.
1 parent 0c0ea69 commit a0c7d88

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ FROM base AS prod-deps
1313
RUN apk add --no-cache libc6-compat
1414
WORKDIR /app
1515
COPY package.json package-lock.json* ./
16-
RUN npm ci --omit=dev
16+
RUN npm ci --omit=dev --ignore-scripts
1717

1818
# Build the application
1919
FROM base AS builder

0 commit comments

Comments
 (0)