From d546dcbebfcb048bb395a79bfb06607af12cb7f1 Mon Sep 17 00:00:00 2001 From: Krakinou Date: Tue, 13 Apr 2021 20:37:37 +0200 Subject: [PATCH] Recreate log folder --- scripts/install | 1 - scripts/restore | 16 ++++++++-------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/scripts/install b/scripts/install index 9b4fab1..3f4e01e 100755 --- a/scripts/install +++ b/scripts/install @@ -178,7 +178,6 @@ ynh_script_progression --message="Integrating service in YunoHost..." --weight=1 yunohost service add $app --description="A DLNA, UPnP and HTTP(S) Media Server." --log="/var/log/$app/$app.log" --needs_exposed_ports "$port_web" "$port_rend" - #================================================= # START SYSTEMD SERVICE #================================================= diff --git a/scripts/restore b/scripts/restore index e0ddb19..a373a95 100755 --- a/scripts/restore +++ b/scripts/restore @@ -125,17 +125,10 @@ ynh_script_progression --message="Integrating service in YunoHost..." --weight=2 yunohost service add $app --description="A DLNA, UPnP and HTTP(S) Media Server." --log=/var/log/$app/$app.log --needs_exposed_ports $port_web $port_rend -#================================================= -# START SYSTEMD SERVICE -#================================================= -ynh_script_progression --message="Starting a systemd service..." --weight=1 - -ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" - #================================================= # RESTORE VARIOUS FILES #================================================= - +mkdir -p /var/log/$app ynh_restore_file --origin_path="/home/$app/" chown -R $app:$app "/home/$app/.config" chmod -R 700 "/home/$app/.config" @@ -146,6 +139,13 @@ chmod -R 700 "/home/$app/.config" ynh_restore_file --origin_path="/etc/logrotate.d/$app" +#================================================= +# START SYSTEMD SERVICE +#================================================= +ynh_script_progression --message="Starting a systemd service..." --weight=1 + +ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/$app.log" + #================================================= # GENERIC FINALIZATION #=================================================