30 lines
672 B
Docker
30 lines
672 B
Docker
FROM eswardudi/python-ffmpeg:3.13.3
|
|
|
|
WORKDIR /app
|
|
|
|
COPY server/py/fastapi_server/requirements_prod.txt ./
|
|
RUN pip install --no-cache-dir -r requirements_prod.txt
|
|
|
|
# This one is necessary for the server
|
|
#RUN apt update && apt install ffmpeg -y
|
|
|
|
#COPY server/py/fastapi_server/ ./
|
|
COPY --chmod=755 ./server/py/fastapi_server/*.py ./
|
|
# Copy the entrypoint to root
|
|
COPY --chmod=755 ./server/py/fastapi_server/entrypoint.sh /
|
|
|
|
ENV PORT=8000
|
|
ENV HOST=0.0.0.0
|
|
ENV DOWNLOAD_FOLDER=/tmp/downloads
|
|
|
|
# Ammount (in secs) before file autodeletes
|
|
ENV FILE_AUTODELETE_DELAY_SECS=300
|
|
|
|
ENV ROOT_PATH=/
|
|
|
|
VOLUME ["/tmp/downloads"]
|
|
|
|
|
|
ENTRYPOINT ["/entrypoint.sh"]
|
|
CMD ["python3", "main.py"]
|