From fc8124dc776d440a6d4d74c9b2005b479ac558f6 Mon Sep 17 00:00:00 2001 From: Hardware Date: Fri, 22 Jun 2018 09:13:40 +0200 Subject: [PATCH] docs(): update readme --- Dockerfile | 2 +- README.md | 2 +- rootfs/usr/local/bin/run.sh | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 2150fb5..1e7379b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,7 +5,7 @@ LABEL description "Rainloop is a simple, modern & fast web-based client" \ ARG GPG_FINGERPRINT="3B79 7ECE 694F 3B7B 70F3 11A4 ED7C 49D9 87DA 4591" -ENV UID=991 GID=991 UPLOAD_MAX_SIZE=25M +ENV UID=991 GID=991 UPLOAD_MAX_SIZE=25M LOG_TO_STDOUT=false RUN echo "@community https://nl.alpinelinux.org/alpine/v3.7/community" >> /etc/apk/repositories \ && apk -U upgrade \ diff --git a/README.md b/README.md index aeeaea0..2d8328f 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ Rainloop is a simple, modern & fast web-based client. More details on the [offic | **UID** | rainloop user id | *optional* | 991 | **GID** | rainloop group id | *optional* | 991 | **UPLOAD_MAX_SIZE** | Attachment size limit | *optional* | 25M -| **LOG_TO_STDOUT** | set to "true" | *optional* | undef +| **LOG_TO_STDOUT** | Enable nginx and php error logs to stdout | *optional* | false ### Docker-compose.yml diff --git a/rootfs/usr/local/bin/run.sh b/rootfs/usr/local/bin/run.sh index 19af137..37c7138 100644 --- a/rootfs/usr/local/bin/run.sh +++ b/rootfs/usr/local/bin/run.sh @@ -9,10 +9,11 @@ if [ -d "/rainloop/data/_data_/_default_/plugins/postfixadmin-change-password" ] fi # Set log output to STDOUT if wanted (LOG_TO_STDOUT=true) -if [ "$LOG_TO_STDOUT" == "true" ]; then +if [ "$LOG_TO_STDOUT" = true ]; then + echo "[INFO] Logging to stdout activated" chmod o+w /dev/stdout sed -i "s/.*error_log.*$/error_log \/dev\/stdout warn;/" /etc/nginx/nginx.conf - echo "Logging to STDOUT activated" > /dev/stdout + sed -i "s/.*error_log.*$/error_log = \/dev\/stdout/" /etc/php7/php-fpm.conf fi # Add postfixadmin-change-password plugin