2025-03-18 14:27:07 +01:00
|
|
|
# Base image for Python
|
2025-01-08 14:59:36 +01:00
|
|
|
FROM python:slim
|
|
|
|
|
|
2025-03-18 14:27:07 +01:00
|
|
|
# Set the working directory
|
2025-01-08 14:59:36 +01:00
|
|
|
WORKDIR /app
|
|
|
|
|
|
2025-03-18 14:27:07 +01:00
|
|
|
# Copy and install dependencies
|
2025-01-08 14:59:36 +01:00
|
|
|
COPY app/requirements.txt requirements.txt
|
|
|
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
|
|
2025-03-18 14:27:07 +01:00
|
|
|
# Copy application code
|
2025-01-08 14:59:36 +01:00
|
|
|
COPY app/ .
|
|
|
|
|
|
2025-07-05 09:32:07 +02:00
|
|
|
# Start command using shell to allow env substitution
|
2025-07-05 10:55:32 +02:00
|
|
|
CMD sh -c "exec python app.py --port=\${PORT}"
|