Updated Dockerfile

This commit is contained in:
Gabe 2023-04-25 09:57:54 +00:00
parent 91f24a81f2
commit 52a263aa20
1 changed files with 10 additions and 5 deletions

View File

@ -3,16 +3,21 @@ FROM python:3.9-alpine as base
RUN apk --update add ffmpeg RUN apk --update add ffmpeg
FROM base as builder FROM base as builder
RUN mkdir /install
RUN apk --update add git
WORKDIR /install WORKDIR /install
COPY requirements.txt /requirements.txt COPY requirements.txt /requirements.txt
RUN apk add gcc libc-dev zlib zlib-dev jpeg-dev \
&& pip install --prefix="/install" -r /requirements.txt
RUN apk add gcc libc-dev zlib zlib-dev jpeg-dev
RUN pip install --prefix="/install" -r /requirements.txt
FROM base FROM base
COPY --from=builder /install /usr/local COPY --from=builder /install /usr/local/lib/python3.9/site-packages
RUN mv /usr/local/lib/python3.9/site-packages/lib/python3.9/site-packages/* /usr/local/lib/python3.9/site-packages/
COPY zotify /app/zotify COPY zotify /app/zotify
WORKDIR /app WORKDIR /app
ENTRYPOINT ["python3", "-m", "zotify"] CMD ["python3", "-m", "zotify"]