2014-11-11 21:07:13 +00:00
|
|
|
#!/bin/sh
|
2014-11-16 13:19:56 +00:00
|
|
|
|
2015-05-10 18:51:19 +00:00
|
|
|
if [ ! -z "${KEEP_TRANSMISSION_STATE}" ]
|
2014-11-16 13:19:56 +00:00
|
|
|
then
|
2015-05-10 18:51:19 +00:00
|
|
|
echo "STARTING TRANSMISSION: Using transmission-data subdirectory to your /data mount point to store state."
|
|
|
|
|
|
|
|
# Initialize settings from environment variables
|
|
|
|
dockerize -template /etc/transmission-daemon/settings.tmpl:/data/transmission-data/settings.json \
|
|
|
|
true
|
|
|
|
|
|
|
|
exec /usr/bin/transmission-daemon -g /data/transmission-data/ &
|
2014-11-16 13:19:56 +00:00
|
|
|
else
|
2015-05-10 18:51:19 +00:00
|
|
|
echo "STARTING TRANSMISSION: Storing state in container only."
|
|
|
|
|
|
|
|
# Initialize settings from environment variables
|
|
|
|
dockerize -template /etc/transmission-daemon/settings.tmpl:/etc/transmission-daemon/settings.json \
|
|
|
|
true
|
|
|
|
|
2015-05-07 19:34:34 +00:00
|
|
|
exec /usr/bin/transmission-daemon -g /etc/transmission-daemon/ &
|
2014-11-16 13:19:56 +00:00
|
|
|
fi
|
2015-05-07 19:34:34 +00:00
|
|
|
|
|
|
|
exec /etc/transmission-daemon/startPortUpdates.sh &
|
|
|
|
|
|
|
|
echo "STARTED PORT UPDATER"
|