Commit 56b8a260 authored by Michał 'rysiek' Woźniak's avatar Michał 'rysiek' Woźniak
Browse files

conflict resolved

parents c8c2937e 31f01bf3
......@@ -36,6 +36,9 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update && \
RUN ln -sf /dev/stdout /var/log/nginx/access.log
RUN ln -sf /dev/stderr /var/log/nginx/error.log
# make sure the log dir exists
RUN mkdir -p /srv/logs/nginx/ && chown www-data:www-data /srv/logs/nginx/
RUN chmod +x /
# Watchful NginX
Watchful NginX container -- nginx docker container that watches for logrotated logfiles and makes sure nginx reloads them when needed.
Watchful NginX container -- `nginx` docker container that watches for logrotated logfiles using `inotify` and makes sure `nginx` reloads them when needed. A nasty, but functional, kludge of a work-around for [lack of PID namespaces in docker](
Upon start it creates a dhparam file in `/etc/ssl/nginx/dhparam.pem` (if the file does not exist) and sets an `inotify` watch on `/srv/logs/nginx/logrotate`. Once the watch discovers that the watchfile has been modified, it sends the `USR1` signal to `nginx`, which causes it to reload the logfiles.
......@@ -15,3 +15,4 @@ postrotate
- watch the logfiles themselves and remove the need for the explicit logrotate flag file
- more configuration options (logfile/watchfile locations, etc)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment