-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enable custom settings.ini for Docker containers
Fixes #73
- Loading branch information
Showing
9 changed files
with
96 additions
and
48 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
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,9 +1,22 @@ | ||
#!/bin/sh | ||
echo "Updating settings.ini" | ||
python /plexanisync/settingsupdater.py | ||
run() { | ||
while true | ||
do | ||
(cd /plexanisync && python PlexAniSync.py) | ||
sleep ${INTERVAL} | ||
done | ||
} | ||
|
||
#### | ||
# Main body of script | ||
### | ||
|
||
if [[ -z "${SETTINGS_FILE}" ]]; then | ||
echo "Updating settings.ini" | ||
python /plexanisync/settingsupdater.py | ||
run | ||
else | ||
echo "Using custom config: "${SETTINGS_FILE} | ||
run | ||
fi | ||
|
||
while true | ||
do | ||
(cd /plexanisync && python PlexAniSync.py) | ||
sleep ${INTERVAL} | ||
done |
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,21 +1,33 @@ | ||
FROM tautulli/tautulli | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y build-essential | ||
|
||
ENV PLEX_SECTION=Anime \ | ||
PLEX_URL=http://127.0.0.1:32400 \ | ||
PLEX_TOKEN='' \ | ||
ANI_USERNAME='' \ | ||
ANI_TOKEN='' | ||
ANI_TOKEN='' \ | ||
SETTINGS_FILE='' | ||
|
||
ADD ./* /plexanisync/ | ||
# run this before copying requirements for cache efficiency | ||
RUN pip install --upgrade pip | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y build-essential && \ | ||
cd /plexanisync && \ | ||
python -m pip install -r requirements.txt && \ | ||
cd .. | ||
#set work directory early so remaining paths can be relative | ||
WORKDIR /plexanisync | ||
|
||
# Adding requirements file to current directory | ||
# just this file first to cache the pip install step when code changes | ||
# Use copy since we are not getting anything from remote or URL | ||
COPY requirements.txt . | ||
COPY Docker/Tautulli/run/start.sh /app/ | ||
COPY Docker/Tautulli/run/settingsupdater.py /plexanisync/ | ||
|
||
# Install dependencies | ||
RUN python3 -m pip install -r requirements.txt | ||
|
||
COPY ./* /plexanisync/ | ||
|
||
LABEL autoheal=true | ||
LABEL org.opencontainers.image.documentation=https://github.com/RickDB/PlexAniSync/blob/master/Docker/Tautulli/README.md | ||
|
||
COPY Docker/Tautulli/run/start.sh /app/ | ||
COPY Docker/Tautulli/run/settingsupdater.py /plexanisync/ |
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
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
Submodule custom-mappings
added at
3acef0