Synapse backup/restore failed

Hi,

I was finally able to restore my synapse server :smiley:

First, I install a fresh version of synapse, then I run manually the restore script with few modifications.

I start by preparing the archive :

sudo tar -xzvf synapse-archive.tar.gz -C ../tmp/
cd /home/yunohost.backup/tmp/apps/synapse/settings

Then I run the restore script changing the following parts.

In load settings, set the app name.

#=================================================
# LOAD SETTINGS
#=================================================
ynh_script_progression --message="Loading settings..."

#app=$YNH_APP_INSTANCE_NAME
app=synapse

In RESTORE DATA, copy-paste the old stuff in the new place.

#=================================================
# RESTORE DATA and LOG and CONFIG
#=================================================
cp -r ../backup/var/lib/matrix-synapse "/var/lib/matrix-$app" 
cp -r ../backup/var/log/matrix-synapse "/var/log/matrix-$app" 
cp -r ../backup/etc/matrix-synapse "/etc/matrix-$app" 

In recreate dedicate user, the ynh_system_user_create was stopping the scripts :open_mouth:

#=================================================
# RECREATE THE DEDICATED USER
#=================================================
ynh_script_progression --message="Recreating the dedicated system user..." --weight=3

# Create the dedicated user (if not existing)
#ynh_system_user_create --username=$synapse_user --home_dir=/var/lib/matrix-$app
adduser $synapse_user ssl-cert
adduser turnserver ssl-cert

The only remaining small issue is they is no automatic connection in riot web app…

Thanks again for the help !
Happy Yunohosting :smiley: