Add LOG_TO_STDOUT variable + documentation (#1379)

This commit is contained in:
Kusha Gharahi
2020-09-28 18:51:59 -05:00
committed by GitHub
parent 2287ee9cc4
commit e3d27e8172
8 changed files with 18 additions and 5 deletions

View File

@@ -97,5 +97,6 @@ export DROP_DEFAULT_ROUTE={{ .Env.DROP_DEFAULT_ROUTE }}
# Support using transmission ids for transmission paths
export GLOBAL_APPLY_PERMISSIONS={{ .Env.GLOBAL_APPLY_PERMISSIONS }}
#Support logging to docker logs
export DOCKER_LOG={{ .Env.DOCKER_LOG }}
# Support logging to stdout which docker logs uses, mark either true
export DOCKER_LOG={{ .Env.DOCKER_LOG }} # DEPRECIATED -- variable name does not reflect usage
export LOG_TO_STDOUT={{ .Env.LOG_TO_STDOUT }} # Updated variable name

View File

@@ -60,7 +60,7 @@ if [[ "true" = "$DROP_DEFAULT_ROUTE" ]]; then
ip r del default || exit 1
fi
if [[ "true" = "$DOCKER_LOG" ]]; then
if [[ "true" = "$DOCKER_LOG" || "true" = "$LOG_TO_STDOUT" ]]; then
LOGFILE=/dev/stdout
else
LOGFILE=${TRANSMISSION_HOME}/transmission.log

View File

@@ -13,7 +13,7 @@ if [ -n "$PUID" ] && [ ! "$(id -u root)" -eq "$PUID" ]; then
groupmod -o -g "$PGID" ${RUN_AS};
fi
if [[ "true" = "$DOCKER_LOG" ]]; then
if [[ "true" = "$DOCKER_LOG" || "true" = "$LOG_TO_STDOUT" ]]; then
chown ${RUN_AS}:${RUN_AS} /dev/stdout
fi