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

Fix config panel

This commit is contained in:
Josué Tille 2020-05-29 22:39:15 +02:00
parent ab2273fe4e
commit c2620569be
No known key found for this signature in database
GPG key ID: 716A6C99B04194EF
2 changed files with 23 additions and 12 deletions

View file

@ -57,6 +57,19 @@ apply_config() {
is_public=${YNH_CONFIG_SYNAPSE_CONFIG_SERVER_CONFIG_IS_PUBLIC:-$is_public}
jitsi_server=${YNH_CONFIG_SYNAPSE_CONFIG_CLIENT_CONFIG_JITSI_SERVER:-$jitsi_server}
if [ $report_stats == 1 ]; then
report_stats=true
fi
if [ $report_stats == 0 ]; then
report_stats=false
fi
if [ $allow_public_rooms == 1 ]; then
allow_public_rooms=true
fi
if [ $allow_public_rooms == 0 ]; then
allow_public_rooms=false
fi
ynh_app_setting_set --app $app --key report_stats --value $report_stats
ynh_app_setting_set --app $app --key allow_public_rooms --value $allow_public_rooms
ynh_app_setting_set --app $app --key is_public --value $is_public

View file

@ -117,6 +117,16 @@ if [ -z $jitsi_server ]; then
ynh_app_setting_set --app=$app --key=jitsi_server --value=$jitsi_server
fi
if [ -z $report_stats ]; then
report_stats="false"
ynh_app_setting_set --app=$app --key=report_stats --value=$report_stats
fi
if [ -z $allow_public_rooms ]; then
allow_public_rooms="false"
ynh_app_setting_set --app=$app --key=allow_public_rooms --value=$allow_public_rooms
fi
#=================================================
# INSTALL DEPENDENCIES
#=================================================
@ -220,18 +230,6 @@ then
fi
ynh_print_ON
#=================================================
# MIGRATION 5 : DEFINE UNDEFINED SETTINGS
#=================================================
if [ -n $report_stats ]; then
report_stats="false"
fi
if [ -n $allow_public_rooms ]; then
allow_public_rooms="false"
fi
#=================================================
# UPDATE SYNAPSE CONFIG
#=================================================