File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ RUN uv sync --frozen --no-dev
3333# Stage 3: Production image with minimal runtime
3434FROM python:3.12-slim AS production
3535
36- # Install only Node.js runtime (no npm/build tools) and bash
36+ # Install Node.js and bash
3737RUN apt-get update && \
3838 apt-get install -y curl bash && \
3939 curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \
@@ -54,9 +54,10 @@ COPY --from=backend-builder /app/.venv /app/.venv
5454COPY backend/*.py ./
5555
5656# Copy built frontend from previous stage
57- COPY --from=frontend-builder /app/frontend/.next/standalone ./
58- COPY --from=frontend-builder /app/frontend/.next/static ./.next/static
57+ COPY --from=frontend-builder /app/frontend/.next ./.next
5958COPY --from=frontend-builder /app/frontend/public ./public
59+ COPY --from=frontend-builder /app/frontend/package.json ./package.json
60+ COPY --from=frontend-builder /app/frontend/node_modules ./node_modules
6061
6162# Expose ports
6263EXPOSE 8000 3000
@@ -73,7 +74,7 @@ ENV PYTHONPATH=/app \
7374RUN echo '#!/bin/bash\n \
7475 uv run uvicorn main:app --host $UVICORN_HOST --port $UVICORN_PORT &\n \
7576 BACKEND_PID=$!\n \
76- PORT=3000 node server.js &\n \
77+ cd /app && PORT=3000 npx next start &\n \
7778 FRONTEND_PID=$!\n \
7879 wait $BACKEND_PID $FRONTEND_PID' > /app/start.sh && chmod +x /app/start.sh
7980
Original file line number Diff line number Diff line change @@ -4,7 +4,6 @@ const withNextIntl = createNextIntlPlugin('./i18n.ts');
44
55/** @type {import('next').NextConfig } */
66const nextConfig = {
7- output : 'standalone' ,
87 compiler : {
98 removeConsole :
109 process . env . NODE_ENV === "production"
You can’t perform that action at this time.
0 commit comments