1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/synapse_ynh.git synced 2024-09-03 20:26:38 +02:00

Fix settings migration

This commit is contained in:
Josué Tille 2019-12-18 20:50:48 +01:00
parent 4d88fe3033
commit a393698f19
No known key found for this signature in database
GPG key ID: 716A6C99B04194EF

View file

@ -64,10 +64,6 @@ then
ynh_die --message="Update from this synapse version is not available. You need to remove this package and reinstall the new package version." ynh_die --message="Update from this synapse version is not available. You need to remove this package and reinstall the new package version."
fi fi
if [ -z $server_name ]; then
server_name=$domain
ynh_app_setting_set $app server_name $domain
fi
#================================================= #=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP # BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#================================================= #=================================================
@ -93,7 +89,7 @@ ynh_abort_if_errors
#================================================= #=================================================
# STANDARD UPGRADE STEPS # STANDARD UPGRADE STEPS
#================================================= #=================================================
# MIGRATION 5 : GENERATE SYNAPSE SECRET # MIGRATION 5 : Manage old settings
#================================================= #=================================================
# Migrate from settings 'special_domain' to 'domain' and 'special_path' to 'path' # Migrate from settings 'special_domain' to 'domain' and 'special_path' to 'path'
@ -107,6 +103,12 @@ if [ -z $domain ]; then
ynh_app_setting_set --app=$app --key=no_sso --value true ynh_app_setting_set --app=$app --key=no_sso --value true
fi fi
# Define $server_name if not already defined
if [ -z $server_name ]; then
server_name=$domain
ynh_app_setting_set $app server_name $domain
fi
#================================================= #=================================================
# INSTALL DEPENDENCIES # INSTALL DEPENDENCIES
#================================================= #=================================================