From 8b708738bf5add43eda5aabb477894a6ff1fc8e6 Mon Sep 17 00:00:00 2001 From: wilmardo Date: Sun, 5 Apr 2020 20:58:10 +0200 Subject: [PATCH] fix: write to /dev/stdout and set permissions Signed-off-by: wilmardo --- transmission/start.sh | 2 +- transmission/userSetup.sh | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/transmission/start.sh b/transmission/start.sh index 2da99df64..12d28c811 100755 --- a/transmission/start.sh +++ b/transmission/start.sh @@ -61,7 +61,7 @@ if [[ "true" = "$DROP_DEFAULT_ROUTE" ]]; then fi if [[ "true" = "$DOCKER_LOG" ]]; then - LOGFILE=/proc/1/fd/1 + LOGFILE=/dev/stdout else LOGFILE=${TRANSMISSION_HOME}/transmission.log fi diff --git a/transmission/userSetup.sh b/transmission/userSetup.sh index c1da9d0a8..b3c3557a8 100644 --- a/transmission/userSetup.sh +++ b/transmission/userSetup.sh @@ -13,6 +13,10 @@ if [ -n "$PUID" ] && [ ! "$(id -u root)" -eq "$PUID" ]; then groupmod -o -g "$PGID" ${RUN_AS}; fi + if [[ "true" = "$DOCKER_LOG" ]]; then + chown ${RUN_AS}:${RUN_AS} /dev/stdout + fi + # Make sure directories exist before chown and chmod mkdir -p /config \ ${TRANSMISSION_HOME} \