Spaces:
Running
Running
Update Dockerfile
Browse files- Dockerfile +2 -2
Dockerfile
CHANGED
|
@@ -19,7 +19,8 @@ RUN npm ci
|
|
| 19 |
RUN npm run build
|
| 20 |
|
| 21 |
# Copy static files to standalone directory (required for standalone mode)
|
| 22 |
-
RUN cp -r
|
|
|
|
| 23 |
|
| 24 |
ENV NODE_ENV=production
|
| 25 |
ENV NEXT_TELEMETRY_DISABLED=1
|
|
@@ -30,4 +31,3 @@ EXPOSE 7860
|
|
| 30 |
|
| 31 |
# Use standalone server for better performance
|
| 32 |
CMD ["node", ".next/standalone/server.js"]
|
| 33 |
-
|
|
|
|
| 19 |
RUN npm run build
|
| 20 |
|
| 21 |
# Copy static files to standalone directory (required for standalone mode)
|
| 22 |
+
RUN cp -r .next/static .next/standalone/.next/ && \
|
| 23 |
+
(cp -r public .next/standalone/ 2>/dev/null || mkdir -p .next/standalone/public)
|
| 24 |
|
| 25 |
ENV NODE_ENV=production
|
| 26 |
ENV NEXT_TELEMETRY_DISABLED=1
|
|
|
|
| 31 |
|
| 32 |
# Use standalone server for better performance
|
| 33 |
CMD ["node", ".next/standalone/server.js"]
|
|
|