mirror of
https://github.com/YunoHost-Apps/synapse_ynh.git
synced 2024-09-03 20:26:38 +02:00
Merge pull request #386 from YunoHost-Apps/fix_app_service
Fix app service config file
This commit is contained in:
commit
9740fc719a
5 changed files with 13 additions and 4 deletions
|
@ -21,7 +21,7 @@ Instant messaging server matrix network.
|
|||
Yunohost chatroom with matrix : [https://matrix.to/#/#yunohost:matrix.org](https://matrix.to/#/#yunohost:matrix.org)
|
||||
|
||||
|
||||
**Shipped version:** 1.84.1~ynh1
|
||||
**Shipped version:** 1.84.1~ynh2
|
||||
## Disclaimers / important information
|
||||
|
||||
## Configuration
|
||||
|
|
|
@ -21,7 +21,7 @@ Instant messaging server matrix network.
|
|||
Yunohost chatroom with matrix : [https://matrix.to/#/#yunohost:matrix.org](https://matrix.to/#/#yunohost:matrix.org)
|
||||
|
||||
|
||||
**Version incluse :** 1.84.1~ynh1
|
||||
**Version incluse :** 1.84.1~ynh2
|
||||
## Avertissements / informations importantes
|
||||
|
||||
## Configuration
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
"en": "Instant messaging server which uses Matrix",
|
||||
"fr": "Serveur de messagerie instantané basé sur Matrix"
|
||||
},
|
||||
"version": "1.84.1~ynh1",
|
||||
"version": "1.84.1~ynh2",
|
||||
"url": "http://matrix.org",
|
||||
"license": "Apache-2.0",
|
||||
"maintainer": {
|
||||
|
|
|
@ -380,7 +380,14 @@ ynh_add_config --template="../sources/update_synapse_for_appservice.sh" --destin
|
|||
|
||||
# Ensure app-service folder has exists and the config file exit (Migration)
|
||||
mkdir -p /etc/matrix-$app/app-service
|
||||
test -e /etc/matrix-$app/conf.d/app_service.yaml || touch /etc/matrix-$app/conf.d/app_service.yaml
|
||||
if [ -e /etc/matrix-$app/conf.d/app_service.yaml ]; then
|
||||
# ensure that the file is empty if no app service are installed (fix issue #385)
|
||||
if [ ! "$(ls -A /etc/matrix-$app/app-service)" ]; then
|
||||
echo "" > /etc/matrix-$app/conf.d/app_service.yaml
|
||||
fi
|
||||
else
|
||||
touch /etc/matrix-$app/conf.d/app_service.yaml
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# ADVERTISE SERVICE IN ADMIN PANEL
|
||||
|
|
|
@ -8,6 +8,8 @@ cp $service_config_file /tmp/app_service_backup.yaml
|
|||
|
||||
if [ -n "$(ls /etc/matrix-$app/app-service/)" ]; then
|
||||
echo "app_service_config_files:" > $service_config_file
|
||||
else
|
||||
echo "" > $service_config_file
|
||||
fi
|
||||
for f in $(ls /etc/matrix-$app/app-service/); do
|
||||
echo " - /etc/matrix-$app/app-service/$f" >> $service_config_file
|
||||
|
|
Loading…
Reference in a new issue