Skip to content

Commit 4a63811

Browse files
committed
fix: speed up build by not building in the container
1 parent b85f82c commit 4a63811

File tree

1 file changed

+6
-18
lines changed

1 file changed

+6
-18
lines changed

Dockerfile

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,16 @@
1-
FROM node:22.14.0 AS build
2-
3-
COPY --from=oven/bun:1.2.8-debian --chmod=0777 /usr/local/bin/bun /bin/bun
4-
5-
RUN mkdir -p /app
6-
WORKDIR /app
7-
8-
COPY --chmod=0777 . .
9-
RUN bun install
10-
RUN bun run build
11-
RUN rm -Rf .next/standalone/.env
12-
13-
# RUN
14-
FROM node:22.14.0-slim
1+
FROM oven/bun:1.2.8
152

163
LABEL org.opencontainers.image.source="https://github.com/settlemint/docs"
174

185
ENV NODE_ENV=production
196
ENV NEXT_TELEMETRY_DISABLED=1
207

21-
# COPY --from=build --chmod=0777 /app/public public
22-
COPY --from=build --chmod=0777 /app/.next/standalone ./
23-
COPY --from=build --chmod=0777 /app/.next/static ./.next/static
8+
COPY --chmod=0777 .next/standalone ./
9+
COPY --chmod=0777 public ./public
10+
COPY --chmod=0777 .next/static ./.next/static
2411

2512
ENV PORT=3000
2613
ENV HOSTNAME="0.0.0.0"
14+
ENV NODE_ENV=production
2715

28-
CMD ["server.js"]
16+
CMD ["bun", "kit/dapp/server.js"]

0 commit comments

Comments
 (0)