From 936326805dccd28258813972e43fbacc4efc2084 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nathana=C3=ABl=20Hannebert?= Date: Thu, 4 Apr 2024 17:57:02 +0200 Subject: [PATCH] fix config file .env was not modified not during upgrade neither during change url --- scripts/change_url | 10 ++++++++++ scripts/upgrade | 10 ++++++++++ 2 files changed, 20 insertions(+) diff --git a/scripts/change_url b/scripts/change_url index 1faa49d..6b35016 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -25,6 +25,16 @@ ynh_script_progression --message="Updating NGINX web server configuration..." -- ynh_change_url_nginx_config +#================================================= +# MODIFY CONFIGURATION +#================================================= +ynh_script_progression --message="Modifying configuration file..." --weight=1 + +ynh_add_config --template="env" --destination="$install_dir/.env" + +chmod 400 "$install_dir/.env" +chown "$app:$app" "$install_dir/.env" + #================================================= # GENERIC FINALISATION #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index d193daa..af5166c 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -30,6 +30,16 @@ chmod -R o-rwx "$install_dir" chown -R "$app:$app" "$install_dir" chmod +x "$install_dir/nocodb" +#================================================= +# UPGRADE CONFIGURATION +#================================================= +ynh_script_progression --message="Upgrade configuration file..." --weight=1 + +ynh_add_config --template="env" --destination="$install_dir/.env" + +chmod 400 "$install_dir/.env" +chown "$app:$app" "$install_dir/.env" + #================================================= # REAPPLY SYSTEM CONFIGURATIONS #=================================================