1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mobilizon_ynh.git synced 2024-09-03 19:46:19 +02:00

Fix upgrade steps

This commit is contained in:
yalh76 2021-04-27 22:56:03 +02:00
parent b4052f3a57
commit 74dc992fce
2 changed files with 1 additions and 13 deletions

View file

@ -28,8 +28,6 @@
upgrade=1 from_commit=cba843be0d7e00d7d7290f0d0da95807711a96d4
# 1.1.0~ynh1
upgrade=1 from_commit=5780e424cf3217bf9d25e5b24beb51f52b6b777e
# 1.1.0~ynh1
upgrade=1 from_commit=5780e424cf3217bf9d25e5b24beb51f52b6b777e
backup_restore=1
multi_instance=1
port_already_use=0
@ -52,5 +50,3 @@ Notification=all
name=1.0.7~ynh1
; commit=5780e424cf3217bf9d25e5b24beb51f52b6b777e
name=1.1.0~ynh1
; commit=5780e424cf3217bf9d25e5b24beb51f52b6b777e
name=1.1.0~ynh1

View file

@ -148,9 +148,7 @@ if [ -z "$datadir" ]; then
chmod -R o-rwx "$datadir"
chown -R $app:$app "$datadir"
if [[ -d "$final_path/$app/uploads/" ]]; then
rsync -a $final_path/$app/uploads/ $datadir/uploads/
fi
rsync -a $final_path/$app/uploads/ $datadir/uploads/
config="$final_path/$app/config/prod.secret.exs"
@ -181,9 +179,6 @@ then
# Backup the config file in the temp dir
cp -af "$final_path/$app/config/prod.secret.exs" "$tmpdir/prod.secret.exs"
# Backup upload dir
rsync -a "$final_path/$app/uploads" "$tmpdir/."
# Remove the app directory securely
ynh_secure_remove --file="$final_path/$app"
@ -193,9 +188,6 @@ then
# Restore the config file
cp -af "$tmpdir/prod.secret.exs" "$final_path/$app/config/prod.secret.exs"
# Restore upload dir
rsync -a "$tmpdir/uploads" "$final_path/$app/."
# Remove the tmp directory securely
ynh_secure_remove --file="$tmpdir"
fi