caff-previewer-wrapper/Dockerfile

18 lines
553 B
Docker
Raw Normal View History

2020-11-27 06:13:13 +01:00
FROM python:3.8-alpine
2020-11-27 18:10:54 +01:00
COPY --from=registry.kmlabz.com/unstablevortex/caff-previewer:latest /usr/local/bin/caff_previewer /usr/local/bin/caff_previewer
2020-11-27 06:13:13 +01:00
WORKDIR /app
ARG RELEASE_ID
ENV RELEASE_ID ${RELEASE_ID:-""}
COPY requirements.txt ./
RUN apk update && apk add imagemagick && pip3 install --no-cache-dir -r requirements.txt && rm -f requirements.txt && adduser -D -H -s /bin/false -u 1000 caffsvc
COPY ./caff_previewer_wrapper .
EXPOSE 8080
USER 1000
ENTRYPOINT ["gunicorn", "-b", "0.0.0.0:8080", "--workers", "4", "--threads", "2", "app:app"]