simple log rotation routine based on newsyslog @franco (#982)

* simple log rotation routine based on newsyslog @franco
* typo error
* set file permissions to 640
This commit is contained in:
Julio Cesar Camargo (JCC)
2018-11-15 17:25:12 +01:00
committed by Fabian Franz BSc
parent 343a8bbeb5
commit aee23b342e
2 changed files with 6 additions and 0 deletions
@@ -5,3 +5,4 @@ mime.types:/usr/local/etc/nginx/mime.types
php_fpm:/etc/rc.conf.d/php_fpm
php-www.conf:/usr/local/etc/php-fpm.d/www.conf
php-webgui.conf:/usr/local/etc/php-fpm.d/webgui.conf
newsyslog.conf:/etc/newsyslog.conf.d/nginx
@@ -0,0 +1,5 @@
# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num]
{% if helpers.exists('OPNsense.Nginx') %}
/var/log/nginx/*access.log www:www 640 14 * @T00 GZB /var/run/nginx.pid 30
/var/log/nginx/*error.log www:www 640 14 * @T00 GZB /var/run/nginx.pid 30
{% endif %}