changed install to only-production

This commit is contained in:
2025-10-26 12:13:37 +01:00
parent 6a1509d807
commit ca3a5d1c0e
2 changed files with 6 additions and 972 deletions

View File

@@ -16,7 +16,7 @@ COPY tsconfig.base.json ./
COPY ecosystem.config.cjs ./ COPY ecosystem.config.cjs ./
# Install root dependencies # Install root dependencies
RUN npm install RUN npm install --only=production
# Copy workspace files # Copy workspace files
COPY backend/ ./backend/ COPY backend/ ./backend/
@@ -27,19 +27,22 @@ RUN npm install --workspace=backend
RUN npm install --workspace=frontend RUN npm install --workspace=frontend
# Build backend first # Build backend first
RUN npm run build --workspace=backend RUN npm run build --only=production --workspace=backend
# Build frontend # Build frontend
RUN npm run build --workspace=frontend RUN npm run build --only=production --workspace=frontend
# Verify Python and OR-Tools installation # Verify Python and OR-Tools installation
RUN python -c "from ortools.sat.python import cp_model; print('OR-Tools installed successfully')" RUN python -c "from ortools.sat.python import cp_model; print('OR-Tools installed successfully')"
# Production stage (same as above) # Production stage (same as above)
FROM node:20-bookworm FROM node:20-bookworm
WORKDIR /app WORKDIR /app
RUN npm install -g pm2 RUN npm install -g pm2
RUN mkdir -p /app/data RUN mkdir -p /app/data
COPY --from=builder /app/backend/dist/ ./dist/ COPY --from=builder /app/backend/dist/ ./dist/
COPY --from=builder /app/backend/package*.json ./ COPY --from=builder /app/backend/package*.json ./

969
package-lock.json generated

File diff suppressed because it is too large Load Diff