From e438a723ac154abfb9c36ba1b63d470f8b5d4112 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 17 Dec 2023 22:17:44 +0100 Subject: [PATCH] Don't overwrite the local settings during upgrade --- scripts/upgrade | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 06bbca8..1245234 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -47,12 +47,8 @@ chown -R $app:www-data "$install_dir" #================================================= ynh_script_progression --message="Configuring Django..." --weight=1 -export prefix="${path#"/"}/" -prefix=${prefix%"/"} -ynh_backup_if_checksum_is_different --file="$install_dir/coin/settings_local.py" -ynh_render_template ../conf/local.py.j2 "$install_dir/coin/settings_local.py" -ynh_store_file_checksum --file="$install_dir/coin/settings_local.py" - +# NB: We do NOT regen the settings_local.py using the template +# because we absolutely don't want to overwrite it chmod 400 "$install_dir/coin/settings_local.py" chown $app "$install_dir/coin/settings_local.py"