From b0e95f93c258e696db131827d86713630ce97acd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Josu=C3=A9=20Tille?= Date: Tue, 9 Apr 2024 22:21:11 +0200 Subject: [PATCH] Avoid to update source if not needed --- scripts/upgrade | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 5284d7a..ab25c56 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -53,8 +53,10 @@ if [ ~"$app" != "$data_dir" ]; then usermod --home "$data_dir" "$app" fi -# Ensure secrets are defined -ynh_setup_source --dest_dir="$install_dir" --source_id=main --full_replace=1 --keep=custom +if [ "$upgrade_type" == UPGRADE_APP ]; then + # Ensure secrets are defined + ynh_setup_source --dest_dir="$install_dir" --source_id=main --full_replace=1 --keep=custom +fi #================================================= # MIGRATION STEP 2 (Set undefined Vars)