From d6e49f4d09ea5698c21960dc84df4b3dc2e81f5d Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Fri, 18 Oct 2019 01:32:48 -0600 Subject: [PATCH] add timezone to params, default UTC in container --- ab-nginx.params.template | 7 +++++++ build/Dockerfile | 1 + 2 files changed, 8 insertions(+) diff --git a/ab-nginx.params.template b/ab-nginx.params.template index 0cf8d01..3ce2c3c 100644 --- a/ab-nginx.params.template +++ b/ab-nginx.params.template @@ -8,6 +8,13 @@ ##### +### Timezone +# This doesn't impact any functionality of the container, but it does make your +# logs easier to understand if they report the correct local time, right? +# (https://en.wikipedia.org/wiki/List_of_tz_database_time_zones) +TZ=Area/Location + + ### NGINX options # Hostnames to which this instance of NGINX should answer: # By default, this is set to '_' meaning 'match anything'. However, that won't diff --git a/build/Dockerfile b/build/Dockerfile index 0c753a1..4311ec8 100644 --- a/build/Dockerfile +++ b/build/Dockerfile @@ -31,6 +31,7 @@ COPY webroot /usr/share/nginx/html/ EXPOSE 80 443 # default environment variables +ENV TZ=Etc/UTC ENV SERVER_NAMES="_" ENV HTTP_PORT=80 ENV HTTPS_PORT=443