From ff321e548bf3c9a7d8f3761b1ca29e1ed14fc5a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Fri, 19 Jan 2024 15:00:34 +0100 Subject: [PATCH] fixes --- scripts/install | 4 ++-- scripts/restore | 2 +- scripts/upgrade | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/install b/scripts/install index 48058fc..6bb0d35 100755 --- a/scripts/install +++ b/scripts/install @@ -48,7 +48,7 @@ chmod o-rwx "$install_dir" chown -R "$app:www-data" "$install_dir" mkdir -p "/var/log/$app" -touch "$log_file" +touch "/var/log/$app/$app.log" chmod o-rwx "/var/log/$app" chown -R "$app:$app" "/var/log/$app" @@ -99,7 +99,7 @@ ynh_script_progression --message="Adding system configurations related to $app.. ynh_add_nginx_config # Create a dedicated systemd config -ynh_add_systemd_config --service="$app" --template="systemd.service" +ynh_add_systemd_config --service="$app" --description="$app service" --template="systemd.service" yunohost service add "$app" --log="/var/log/$app/$app.log" # Use logrotate to manage app-specific logfile(s) diff --git a/scripts/restore b/scripts/restore index c49a52a..7b32ed1 100755 --- a/scripts/restore +++ b/scripts/restore @@ -42,7 +42,7 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" ynh_restore_file --origin_path="/etc/systemd/system/$app.service" systemctl enable "$app.service" --quiet -yunohost service add "$app" --description="Digital signage system for high schools" --log="/var/log/$app/$app.log" +yunohost service add "$app" --description="$app service" --log="/var/log/$app/$app.log" ynh_restore_file --origin_path="/etc/logrotate.d/$app" diff --git a/scripts/upgrade b/scripts/upgrade index 6eb2411..01e9127 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -99,7 +99,7 @@ ynh_script_progression --message="Upgrading system configurations related to $ap ynh_add_nginx_config 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" +yunohost service add "$app" --description="$app service" --log="/var/log/$app/$app.log" ynh_use_logrotate --non-append chmod o-rwx "/var/log/$app"