From b3d252a031f758ec9ff0218e3382e7e1231321f5 Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 26 Jun 2015 12:33:50 +1000 Subject: [PATCH] allow nginx logs to be read by the web --- templates/web.template.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/templates/web.template.yml b/templates/web.template.yml index d0b7519..2ff1483 100644 --- a/templates/web.template.yml +++ b/templates/web.template.yml @@ -33,6 +33,13 @@ run: # find DISCOURSE_ env vars, strip the leader, lowercase the key /usr/local/bin/ruby -e 'ENV.each{|k,v| puts "#{$1.downcase} = #{v}" if k =~ /^DISCOURSE_(.*)/}' > $conf + - file: + path: /etc/runit/1.d/ensure-web-nginx-read + chmod: "+x" + contents: | + #!/bin/bash + chgrp -R www-data /var/log/nginx + chgrp www-data /var/log/nginx - file: path: /etc/service/unicorn/run chmod: "+x" @@ -199,7 +206,7 @@ run: compress delaycompress notifempty - create 0640 www-data adm + create 0640 www-data www-data sharedscripts postrotate sv 1 nginx -- 2.25.1