FROM python:alpine RUN mkdir /app COPY requirements.txt gunicorn.conf run.py /app/ COPY files/ /app/files ENV FLASK_APP=files WORKDIR /app RUN apk add mariadb-connector-c-dev gcc musl-dev RUN pip install --no-cache-dir -r requirements.txt RUN apk del gcc musl-dev EXPOSE 8080 CMD ["gunicorn", "--config", "gunicorn.conf", "run:app"]