From dc51634b1712f551ef995021e1adc9d658441d3e Mon Sep 17 00:00:00 2001 From: Fabian Wilkens Date: Sat, 30 Jan 2021 00:01:47 +0100 Subject: [PATCH] Fix path-url - config file --- scripts/change_url | 2 ++ scripts/install | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/change_url b/scripts/change_url index 2f2bd5b..2c33704 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -88,6 +88,8 @@ then path_url="$new_path" # Create a dedicated NGINX config ynh_add_nginx_config + # Change config file + ynh_replace_string --match_string="'PSM_BASE_URL', '.*'" --replace_string="'PSM_BASE_URL', '$path_url'" --target_file="$final_path/config.php" fi # Change the domain for NGINX diff --git a/scripts/install b/scripts/install index d8cc1b9..7f371d4 100755 --- a/scripts/install +++ b/scripts/install @@ -161,7 +161,7 @@ cp -a $final_path/config.php.sample $final_path/config.php ynh_replace_string --match_string="db_user" --replace_string=$db_user --target_file="$final_path/config.php" ynh_replace_string --match_string="db_pass" --replace_string=$db_pwd --target_file="$final_path/config.php" ynh_replace_string --match_string="db_name" --replace_string=$db_name --target_file="$final_path/config.php" -ynh_replace_string --match_string='PSM_BASE_URL', '' --replace_string='PSM_BASE_URL',$path_url --target_file="$final_path/config.php" +ynh_replace_string --match_string="'PSM_BASE_URL', ''" --replace_string="'PSM_BASE_URL', '$path_url'" --target_file="$final_path/config.php" #================================================= # STORE THE CONFIG FILE CHECKSUM #=================================================