From ab9cdda49ba75318351a786268e5d0935de6a3d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Fri, 19 Jan 2024 14:54:54 +0100 Subject: [PATCH] fix : remove log_path --- scripts/install | 10 +++++----- scripts/upgrade | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/scripts/install b/scripts/install index 4c602e6..48058fc 100755 --- a/scripts/install +++ b/scripts/install @@ -11,8 +11,8 @@ source /usr/share/yunohost/helpers mkdir -p "$install_dir/public/media" "$install_dir/public/static" mkdir -p "$install_dir" -mkdir -p "$log_path" -touch "${/var/log/$app/$app.log}" +mkdir -p "/var/log/$app" +touch "/var/log/$app/$app.log" redis_db=$(ynh_redis_get_free_db) ynh_app_setting_set --app="$app" --key=redis_db --value="$redis_db" @@ -47,11 +47,11 @@ mkdir -p "$install_dir/public/media" "$install_dir/public/static" chmod o-rwx "$install_dir" chown -R "$app:www-data" "$install_dir" -mkdir -p "$log_path" +mkdir -p "/var/log/$app" touch "$log_file" -chmod o-rwx "$log_path" -chown -R "$app:$app" "$log_path" +chmod o-rwx "/var/log/$app" +chown -R "$app:$app" "/var/log/$app" #================================================= # copy config files diff --git a/scripts/upgrade b/scripts/upgrade index df676e8..6eb2411 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -102,8 +102,8 @@ ynh_add_systemd_config --service="$app" --template="systemd.service" yunohost service add "$app" --description="Digital signage system for high schools" --log="/var/log/$app/$app.log" ynh_use_logrotate --non-append -chmod o-rwx "$log_path" -chown -R "$app:" "$log_path" +chmod o-rwx "/var/log/$app" +chown -R "$app:" "/var/log/$app" #================================================= # Start the app server via systemd