FROM registry.hub.docker.com/library/python:3.10-alpine3.16 WORKDIR /app COPY requirements.txt ./ RUN pip install --no-cache-dir --require-hashes -r requirements.txt COPY * ./ EXPOSE 8080 ENV FORWARDED_ALLOW_IPS "*" HEALTHCHECK CMD wget --spider --quiet http://localhost:8080/ping --user-agent 'Docker Healthcheck' || exit 1 CMD ["gunicorn", "--bind", "0.0.0.0:8080", "--log-file", "-", "--workers", "2", "app:app"]