Skip to content

Commit ac1b166

Browse files
coliseeRobin Alexander
andauthored
Add workaround so that log app.log and sql.log messages are visible with docker logs (#160)
Co-authored-by: Robin Alexander <colisee@hotmail>
1 parent f62cbc5 commit ac1b166

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

bin/entrypoint.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,5 +120,11 @@ if ! [ -z "${APP_PATH}" ]; then
120120
-e "s:\(RewriteRule .*\) /Web/:\1 /${APP_PATH}/Web/:"
121121
fi
122122

123+
# Send log files to /dev/stdout as background jobs
124+
touch "${LB_LOGGING_FOLDER}/app.log"
125+
tail --follow "${LB_LOGGING_FOLDER}/app.log" >> /dev/stdout &
126+
touch "${LB_LOGGING_FOLDER}/sql.log"
127+
tail --follow "${LB_LOGGING_FOLDER}/sql.log" >> /dev/stdout &
128+
123129
# Switch to the apache server
124130
exec "$@"

0 commit comments

Comments
 (0)