From 670b8ab50c046c3d2f468366527bc28a2f5e13ed Mon Sep 17 00:00:00 2001 From: Annika Merris Date: Mon, 5 Feb 2024 09:29:33 -0500 Subject: [PATCH] Switching The Build Step To Node --- Dockerfile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 39d8468..ce83426 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,14 +16,16 @@ RUN cd /temp/prod && bun install --frozen-lockfile --production # copy node_modules from temp directory # then copy all (non-ignored) project files into the image -FROM base AS prerelease +FROM node:21-bookworm AS prerelease +WORKDIR /app + COPY --from=install /temp/prod/node_modules node_modules COPY . . # I don't have any tests, I am bad. ENV NODE_ENV=production RUN cat -e vite.config.ts -RUN bunx --bun vite build --debug true --logLevel info +RUN npx vite build # Copy the distribution folder into the final image. FROM nginx:stable-alpine as release