From e58b73096ffc75ecac7698c8aff715223347d73f Mon Sep 17 00:00:00 2001 From: rodinux Date: Mon, 18 Sep 2023 20:36:06 +0200 Subject: [PATCH] more readable process upgrade --- scripts/upgrade | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 3f98542..7f39c5d 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -30,7 +30,7 @@ if [[ -z "${secret_key:-}" ]]; then fi #================================================= -# BACKUP SQLITE DATABASE +# BACKUP SQLITE DATABASE AND DATAS #================================================= ynh_script_progression --message="Backup of the DB in temporary file...." --weight=5 @@ -88,9 +88,19 @@ fi ynh_add_config --template="config.local.php" --destination="$install_dir/config.local.php" ynh_add_config --template="config.local.yunohost.php" --destination="$install_dir/config.local.yunohost.php" +#================================================= +# RESTORE BACKUP SQLITE DATABASE AND DATAS +#================================================= +ynh_script_progression --message="Restore datas..." --weight=5 + # Sync data directory backup rsync -a $tmp_data_backup/ $install_dir/data/ +#================================================= +# FIX PERMISSIONS +#================================================= +ynh_script_progression --message="Fix permissions..." --weight=2 + # Permissions on files and directories chmod -R o-rwx "$install_dir" chown -R $app:www-data "$install_dir"