Update next.config.mjs and package.json

This commit is contained in:
6drf21e
2024-03-30 10:11:53 +08:00
parent d0530d4199
commit d5c2869098
5 changed files with 28 additions and 37 deletions
+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