We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ac78faf commit 768a6f7Copy full SHA for 768a6f7
docker/Dockerfile
@@ -1,8 +1,17 @@
1
# Using 18 alpine because supports arm/v8 and arm/v8 needed for silicon chips
2
-FROM node:18-alpine
+
3
+# Builder stage with build tools
4
+FROM node:18-alpine AS builder
5
RUN apk add --no-cache bash python3 make g++
6
WORKDIR /app
7
ADD ./ .
8
RUN npm install
9
RUN npm run build
10
11
+# Runtime stage - minimal
12
+FROM node:18-alpine
13
+RUN apk add --no-cache bash
14
+WORKDIR /app
15
+ADD ./ .
16
+COPY --from=builder /app/node_modules /app/node_modules
17
CMD ["npm", "start"]
0 commit comments