Création dossier docker pour build avec Dockerfile, requirements et dossier src

This commit is contained in:
Gu1llaum-3 2023-01-03 07:45:30 +01:00
parent 9c4a98bb60
commit 3186fce279
2 changed files with 30 additions and 0 deletions

28
Docker/Dockerfile Normal file
View File

@ -0,0 +1,28 @@
FROM alpine:latest
# set the working directory in the container
WORKDIR /app
# copy the dependencies file to the working directory
COPY requirements.txt .
# Update packages
RUN apk update
# Install python3 et pip
RUN apk add python3 py3-pip
# install dependencies
RUN pip install -r requirements.txt
# install ffmpeg for SpotDL
RUN spotdl --download-ffmpeg
# install zip
RUN apk update && apk add zip
# copy the content of the local src directory to the working directory
COPY src/ .
# command to run on container start
CMD [ "python", "./app.py" ]

2
Docker/requirements.txt Normal file
View File

@ -0,0 +1,2 @@
spotdl
flask