Change Docker handling of custom rewrites

This commit is contained in:
Maxime-J 2025-04-19 19:44:27 +02:00
parent 3b5e1da39e
commit b88432fcf4
4 changed files with 78 additions and 62 deletions

View file

@ -13,7 +13,6 @@ FROM node:22-alpine AS builder
WORKDIR /app
COPY --from=deps /app/node_modules ./node_modules
COPY . .
COPY docker/middleware.js ./src
ARG DATABASE_TYPE
ARG BASE_PATH
@ -51,6 +50,8 @@ COPY --from=builder /app/scripts ./scripts
COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./
COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
RUN mv ./.next/routes-manifest.json ./.next/routes-manifest-orig.json
USER nextjs
EXPOSE 3000