更新dockerfile,适配Zeabur

This commit is contained in:
fatwang2
2024-03-30 12:30:47 +08:00
parent 010e8e66c8
commit 65e3214649
+1 -1
View File
@@ -4,12 +4,12 @@ WORKDIR /app
# Install dependencies
COPY ./web/package*.json ./
ENV NODE_ENV production
RUN npm install
COPY ./web .
# Compile Next.js and configure distDir
RUN sed -i 's/distDir:.*/distDir: process.env.NEXT_DIST_DIR || ".\/ui"/' next.config.mjs
ENV NODE_ENV production
ENV NEXT_DIST_DIR ./NEXT_BUILD
RUN npm run build