Change dockerfile for faster builds. Incl. ffmpeg
This commit is contained in:
parent
cc362e5ceb
commit
3e91e04bfe
1 changed files with 10 additions and 1 deletions
11
Dockerfile
11
Dockerfile
|
@ -1,7 +1,11 @@
|
|||
FROM python:3.9
|
||||
|
||||
# TODO manually compile ffmpeg, to prevent useless deps and decrease build size
|
||||
# for that, see here: https://stackoverflow.com/questions/53944487/how-to-install-ffmpeg-in-a-docker-container
|
||||
# pin ffmpeg version to prevent issues down the road
|
||||
RUN apt-get update && apt-get -y install ffmpeg=7:4.3.*
|
||||
|
||||
RUN mkdir /app
|
||||
COPY /app /app
|
||||
COPY pyproject.toml /app
|
||||
COPY poetry.lock /app
|
||||
|
||||
|
@ -11,4 +15,9 @@ RUN pip3 install poetry
|
|||
RUN poetry config virtualenvs.create false
|
||||
RUN poetry install --no-dev
|
||||
|
||||
# copy files as late as possible, these change the most
|
||||
# forcing a rerun of all layers
|
||||
COPY /app /app
|
||||
|
||||
|
||||
ENTRYPOINT poetry run python webserver.py --storage /files
|
||||
|
|
Loading…
Reference in a new issue