mirror of
https://github.com/YunoHost-Apps/nextcloud_ynh.git
synced 2024-09-03 19:55:57 +02:00
Update upgrade
This commit is contained in:
parent
c2d5eb88e4
commit
ec95a9dfba
1 changed files with 20 additions and 20 deletions
|
@ -55,31 +55,31 @@ fi
|
||||||
#=================================================
|
#=================================================
|
||||||
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
|
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." --weight=30
|
# ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." --weight=30
|
||||||
|
|
||||||
# Made a backup only after the version 11.0.0
|
# # Made a backup only after the version 11.0.0
|
||||||
# Before, the datas will be always saved.
|
# # Before, the datas will be always saved.
|
||||||
# Get the current version number of nextcloud/owncloud
|
# # Get the current version number of nextcloud/owncloud
|
||||||
current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2)
|
# current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2)
|
||||||
current_major_version=${current_version%%.*}
|
# current_major_version=${current_version%%.*}
|
||||||
|
|
||||||
if [ $current_major_version -gt 11 ]
|
# if [ $current_major_version -gt 11 ]
|
||||||
then
|
# then
|
||||||
# Inform the backup/restore process that it should not save the data directory
|
# # Inform the backup/restore process that it should not save the data directory
|
||||||
# Use only for the previous backup script that doesn't set 'is_big'
|
# # Use only for the previous backup script that doesn't set 'is_big'
|
||||||
ynh_app_setting_set --app=$app --key=backup_core_only --value=1
|
# ynh_app_setting_set --app=$app --key=backup_core_only --value=1
|
||||||
|
|
||||||
# Backup the current version of the app
|
# # Backup the current version of the app
|
||||||
ynh_backup_before_upgrade
|
# ynh_backup_before_upgrade
|
||||||
|
|
||||||
# Remove the option backup_core_only after the backup.
|
# # Remove the option backup_core_only after the backup.
|
||||||
ynh_app_setting_delete $app backup_core_only
|
# ynh_app_setting_delete $app backup_core_only
|
||||||
|
|
||||||
ynh_clean_setup () {
|
# ynh_clean_setup () {
|
||||||
# restore it if the upgrade fails
|
# # restore it if the upgrade fails
|
||||||
ynh_restore_upgradebackup
|
# ynh_restore_upgradebackup
|
||||||
}
|
# }
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# PHP-FPM CONFIGURATION
|
# PHP-FPM CONFIGURATION
|
||||||
|
|
Loading…
Add table
Reference in a new issue