copying database folder seperate

This commit is contained in:
2025-10-22 19:21:13 +02:00
parent ebb9e3f4fe
commit 49afd75ed3

View File

@@ -17,13 +17,13 @@ COPY backend/tsconfig.json ./
# Install backend dependencies # Install backend dependencies
RUN npm ci RUN npm ci
# Copy backend source # Copy backend source and database files
COPY backend/src/ ./src/ COPY backend/src/ ./src/
COPY backend/database/ ./database/
# Build backend # Build backend
RUN npm run build RUN npm run build
# 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')"
@@ -58,6 +58,7 @@ RUN npm install -g pm2
COPY --from=backend-builder /app/backend/package*.json ./ COPY --from=backend-builder /app/backend/package*.json ./
COPY --from=backend-builder /app/backend/dist/ ./dist/ COPY --from=backend-builder /app/backend/dist/ ./dist/
COPY --from=backend-builder /app/backend/node_modules/ ./node_modules/ COPY --from=backend-builder /app/backend/node_modules/ ./node_modules/
COPY --from=backend-builder /app/backend/database/ ./dist/database/
# Copy frontend built files # Copy frontend built files
COPY --from=frontend-builder /app/frontend/build/ ./frontend-build/ COPY --from=frontend-builder /app/frontend/build/ ./frontend-build/
@@ -72,10 +73,6 @@ RUN addgroup -g 1001 -S nodejs && \
USER schichtplan USER schichtplan
# Verify installations
#RUN python --version && \
# python -c "from ortools.sat.python import cp_model; print('OR-Tools verified')"
EXPOSE 3000 3002 EXPOSE 3000 3002
HEALTHCHECK --interval=30s --timeout=10s --start-period=40s --retries=3 \ HEALTHCHECK --interval=30s --timeout=10s --start-period=40s --retries=3 \