updated python installation to break system packages

This commit is contained in:
2025-11-03 10:55:07 +01:00
parent 4c275993e6
commit 7c63bee1b3

View File

@@ -1,5 +1,5 @@
# Single stage build for workspaces # Single stage build for workspaces
FROM node:20-bullseye AS builder FROM node:20-bookworm AS builder
WORKDIR /app WORKDIR /app
@@ -28,7 +28,7 @@ RUN npm run build --only=production --workspace=backend
RUN npm run build --only=production --workspace=frontend RUN npm run build --only=production --workspace=frontend
# Production stage # Production stage
FROM node:20-bullseye FROM node:20-bookworm
WORKDIR /app WORKDIR /app
@@ -56,7 +56,7 @@ COPY --from=builder /app/backend/src/python-scripts/ ./python-scripts/
# Install Python + OR-Tools # Install Python + OR-Tools
RUN apt-get update && apt-get install -y python3 python3-pip build-essential \ RUN apt-get update && apt-get install -y python3 python3-pip build-essential \
&& pip install --no-cache-dir ortools && pip install --no-cache-dir --break-system-packages ortools
# Create symlink so python3 is callable as python # Create symlink so python3 is callable as python
RUN ln -sf /usr/bin/python3 /usr/bin/python RUN ln -sf /usr/bin/python3 /usr/bin/python