FROM python:3.11-slim # Set the working directory in the container WORKDIR /app # Copy the current directory contents into the container at /app COPY . /app RUN apt-get update && apt-get install -y libpq-dev && rm -rf /var/lib/apt/lists/* COPY requirements.txt . RUN pip install -r requirements.txt RUN mkdir -p output/csv output/plots output/models ENV FLASK_APP=wsgi.py ENV FLASK_RUN_HOST=0.0.0.0 EXPOSE 8000 CMD ["gunicorn", "-w", "4", "-b", "0.0.0.0:8000", "wsgi:wsgi_app"]