# Use an official Python runtime as a parent image FROM python:3.10-slim # Set the working directory in the container WORKDIR /app # Copy the dependencies file to the working directory COPY requirements.txt . # Install any needed packages specified in requirements.txt RUN pip install --no-cache-dir -r requirements.txt # Copy only application source (avoid copying dev files) COPY app.py /app/app.py COPY templates /app/templates COPY static /app/static COPY run.sh /app/run.sh # Make run.sh executable RUN chmod +x /app/run.sh # Expose port 10000 EXPOSE 10000 # Default entrypoint uses run.sh which starts gunicorn with configurable workers CMD ["/app/run.sh"]