mirror of
https://github.com/YunoHost-Apps/sogo_ynh.git
synced 2024-09-03 20:26:07 +02:00
Update upgrade
This commit is contained in:
parent
5518182dd4
commit
317da9ecc7
1 changed files with 5 additions and 21 deletions
|
@ -49,36 +49,20 @@ ynh_abort_if_errors
|
||||||
#=================================================
|
#=================================================
|
||||||
# UPGRADE SETTINGS FROM OLD INSTALL
|
# UPGRADE SETTINGS FROM OLD INSTALL
|
||||||
#=================================================
|
#=================================================
|
||||||
|
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
|
||||||
|
|
||||||
ynh_script_progression --message="Fixing old settings..." --weight=1
|
if [[ -z $port ]]; then
|
||||||
|
|
||||||
if [[ ${is_public,,*} = "yes" ]]
|
|
||||||
then
|
|
||||||
is_public=1
|
|
||||||
ynh_app_setting_set --app $app --key is_public --value 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ${is_public,,*} = "no" ]]
|
|
||||||
then
|
|
||||||
is_public=0
|
|
||||||
ynh_app_setting_set --app $app --key is_public --value 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -z $port ]]
|
|
||||||
then
|
|
||||||
# Find a port for SOGo
|
# Find a port for SOGo
|
||||||
port=$(ynh_find_port --port 20000)
|
port=$(ynh_find_port --port=20000)
|
||||||
ynh_app_setting_set --app=$app --key=web_port --value=$port
|
ynh_app_setting_set --app=$app --key=web_port --value=$port
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z $db_name ]]
|
if [[ -z $db_name ]]; then
|
||||||
then
|
|
||||||
db_name=$app
|
db_name=$app
|
||||||
ynh_app_setting_set --app=$app --key=db_name --value=$db_name
|
ynh_app_setting_set --app=$app --key=db_name --value=$db_name
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z $db_user ]]
|
if [[ -z $db_user ]]; then
|
||||||
then
|
|
||||||
db_user=$app
|
db_user=$app
|
||||||
ynh_app_setting_set --app=$app --key=db_user --value=$db_user
|
ynh_app_setting_set --app=$app --key=db_user --value=$db_user
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue