From 7f5d36603dd8a6f73f9c2cefc3dfde796059f79d Mon Sep 17 00:00:00 2001 From: George Robinson Date: Tue, 10 May 2016 12:06:42 +0100 Subject: [PATCH] Set /var/log/nginx writable by NGINX worker processes --- nginx/ng/config.sls | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nginx/ng/config.sls b/nginx/ng/config.sls index 32cf845..4d2ed1d 100644 --- a/nginx/ng/config.sls +++ b/nginx/ng/config.sls @@ -5,9 +5,11 @@ {% from 'nginx/ng/map.jinja' import nginx, sls_block with context %} {% if nginx.install_from_source %} -nginx_log_directory: +nginx_log_dir: file.directory: - name: /var/log/nginx + - user: {{ nginx.server.config.user }} + - group: {{ nginx.server.config.user }} {% endif %} nginx_config: