-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Finished dockerfile, fixed logging error in threads, Improved readmes…
…, Updated dependencies Update Dockerfile, config.json, and 4 more files...
- Loading branch information
1 parent
294e9db
commit 3c55ee3
Showing
6 changed files
with
59 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,38 @@ | ||
# This should be the lightest image. | ||
FROM python:alpine | ||
|
||
# Installing dependencies | ||
# Reading the build arguments. | ||
# * BUID -> Build UID | ||
# * BGID -> Build GID | ||
ARG BUID=1000 | ||
ARG BGID=1000 | ||
|
||
# Installing dependencies. | ||
# * 'g++', 'make' -> Compiling some dependencies. | ||
# * 'py3-lxml' -> Pre-compiled module, allows you to ignore compilation errors. | ||
|
||
# Used to compile lxml for streamlink (Not used for the moment) | ||
# RUN apk add --no-cache libxslt-dev libxml2-dev | ||
|
||
# Used for compiling streamlink and its dependencies | ||
RUN apk update && apk upgrade && \ | ||
apk add --no-cache g++ make py3-lxml ffmpeg | ||
|
||
# Installing required Python packages | ||
RUN pip install --upgrade streamlink==2.3.0 yt-dlp==2021.12.01 | ||
# Previously used to compile lxml for streamlink. (Not used for the moment) | ||
# RUN apk add --no-cache libxslt-dev libxml2-dev | ||
|
||
# Installing required Python packages. | ||
ADD --chown=BUID:BGID ./requirements.txt /app/requirements.txt | ||
RUN pip install --upgrade -r /app/requirements.txt | ||
|
||
# Removing packages that are no longer needed and were used for compiling streamlink and its dependencies | ||
# Removing packages that are no longer needed and were used for compiling streamlink and its dependencies. | ||
# * Some are left however: libgcc, libstdc++, libgomp and gmp | ||
# * Reduces the HDD usage from 198 MiB to 127 MiB for these packages | ||
RUN apk del g++ make | ||
|
||
# Reading the build arguments | ||
# * BUID -> Build UID | ||
# * BGID -> Build GID | ||
ARG BUID=1000 | ||
ARG BGID=1000 | ||
|
||
# Copying the app's files to the container | ||
ADD --chown=BUID:BGID . /app | ||
|
||
# Running the application | ||
# Running the application. | ||
# * Thanks to jdpus for the "-u" flag, it fixes the output (https://stackoverflow.com/a/29745541/4135541) | ||
WORKDIR /app | ||
USER $BUID:$BGID | ||
CMD ["python", "-u", "/app/app.py"] | ||
|
||
# Used for debugging | ||
# Used for debugging. | ||
#CMD ["tail", "-f", "/dev/null"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
streamlink>=3.1.1,<4.0.0 | ||
yt-dlp==2021.12.01 | ||
yt-dlp>=2022.02.04 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters