From 2585830884b959a5062046813bbae22854e44a90 Mon Sep 17 00:00:00 2001 From: lapineige Date: Tue, 14 Feb 2023 21:04:54 +0100 Subject: [PATCH] Restrict permission on log file Incorrect permissions make logrotate fails `error: skipping "/var/log/pixelfed/pixelfed-horizon.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.` --- scripts/install | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/install b/scripts/install index cf94b71f..2113c2dd 100644 --- a/scripts/install +++ b/scripts/install @@ -135,6 +135,7 @@ ynh_script_progression --message="Creating log file..." --weight=1 mkdir -p "/var/log/$app/" touch "/var/log/$app/${app}-horizon.log" chown -R $app: "/var/log/$app/" +chmod 600 $app: "/var/log/$app/" #================================================= # ADD A CONFIGURATION