diff options
author | chris5560 <christian.schoenebeck@gmail.com> | 2014-07-23 21:50:16 +0200 |
---|---|---|
committer | chris5560 <christian.schoenebeck@gmail.com> | 2014-07-23 21:50:16 +0200 |
commit | a909d2d7a27b109eee32c114e41e106d52f4c732 (patch) | |
tree | 358f66523baea165bcc788508cd7927f03583a03 /net/lighttpd/files | |
parent | e2cd0c4b9fd292c440ee40475179191ec7551972 (diff) |
[PATCH] lighttpd: errorlog failed as non root user
if running as non root user (what's should be the default on web-servers) you get:
(log.c.118) opening errorlog '/var/log/lighttpd/server.log' failed: Permission denied
Fix: create log directory only if not exist and chmod 777 to allow anyone
to write and create files inside default log directory
Signed-off-by: Christian Schoenebeck <christian.schoenebeck@gmail.com>
Diffstat (limited to 'net/lighttpd/files')
-rw-r--r-- | net/lighttpd/files/lighttpd.init | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/lighttpd/files/lighttpd.init b/net/lighttpd/files/lighttpd.init index d73a5da98..b318a023d 100644 --- a/net/lighttpd/files/lighttpd.init +++ b/net/lighttpd/files/lighttpd.init @@ -6,7 +6,8 @@ SERVICE_USE_PID=1 START=50 start() { - mkdir -m 0755 -p /var/log/lighttpd + [ -d /var/log/lighttpd ] || mkdir -p /var/log/lighttpd + chmod 0777 /var/log/lighttpd service_start /usr/sbin/lighttpd -f /etc/lighttpd/lighttpd.conf } |