From af9c8774d3c8df7c3baec6b5585ca4fc4c87aaf9 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Sat, 1 Jun 2019 06:51:06 +0200 Subject: [PATCH] backup config before modifying it --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index d5501d4..5462c41 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -134,6 +134,7 @@ ynh_system_user_create --username=$app --home_dir=$final_path #================================================= config="$final_path/$app/.env" +ynh_backup_if_checksum_is_different --file="$config" cp ../conf/.env "$config" ynh_replace_string --match_string="__DOMAIN__" --replace_string="$domain" --target_file="$config" @@ -183,7 +184,6 @@ popd # STORE THE CONFIG FILE CHECKSUM #================================================= -ynh_backup_if_checksum_is_different --file="$config" # Recalculate and store the checksum of the file for the next upgrade. ynh_store_file_checksum --file="$config"