Chris Vogel 1 год назад
Родитель
Сommit
10984006fa
1 измененных файлов с 11 добавлено и 2 удалено
  1. 11 2
      scripts/backup

+ 11 - 2
scripts/backup

@@ -18,8 +18,17 @@ ynh_print_info --message="Stopping flohmarkt and couchdb to backup data..."
 yunohost service stop flohmarkt
 systemctl stop couchdb
 
-ynh_backup --src_path="$data_dir" --is_big
-ynh_backup --src_path="/var/lib/couchdb" --is_big
+# since this might be re-installed as a dependency during 'remove' and 
+# 'install' anew (like after a failed upgrade) we do not want to use
+# --is_big even thought the directories might be big because:
+# "don't want that your package does backup that part during ynh_backup_before_upgrade"
+# https://yunohost.org/en/packaging_apps_scripts_helpers#ynh-backup
+# 
+# if this becomes a pain we'll need to stop deleting this directories on 'remove'
+# ynh_backup --src_path="$data_dir" --is_big
+# ynh_backup --src_path="/var/lib/couchdb" --is_big
+ynh_backup --src_path="$data_dir"
+ynh_backup --src_path="/var/lib/couchdb"
 
 ynh_print_info --message="...done. Starting couchdb and flohmarkt."
 systemctl start couchdb