Add sharp build deps to Dockerfile
This commit is contained in:
+5
-1
@@ -3,9 +3,13 @@ FROM node:20-alpine
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Install libvips build deps for sharp (removed after npm ci for smaller image)
|
||||
RUN apk add --no-cache build-base python3
|
||||
|
||||
# Copy package files first for better layer caching
|
||||
COPY package*.json ./
|
||||
RUN npm ci --omit=dev
|
||||
RUN npm ci --omit=dev && \
|
||||
apk del build-base python3
|
||||
|
||||
# Copy application code
|
||||
COPY server.js ./
|
||||
|
||||
Reference in New Issue
Block a user