From c4c0747c46c7d50148e863f6573639974889c710 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 18 Aug 2021 13:15:09 +0200 Subject: [PATCH] Update change_url --- scripts/change_url | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/scripts/change_url b/scripts/change_url index 8cc24b6..8fe9a2a 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -100,18 +100,22 @@ fi #================================================= ynh_script_progression --message="Updating a configuration file..." --weight=1 -domain=${new_domain%/} -path=${new_path%/} +#domain=${new_domain%/} +#path=${new_path%/} # ynh_replace_string --match_string="\$CFG->wwwroot = .*" --replace_string="\$CFG->wwwroot = 'https://' . '$new_domain' . '${new_path%/}';" --target_file="$final_path/config.php" +ynh_replace_string --match_string="\$CFG->wwwroot = \'.*\'" --replace_string="\$CFG->wwwroot = \'https://${new_domain%/}${new_path%/}\'" --target_file="$final_path/config.php" + + # chmod 750 "$final_path" # chmod -R o-rwx "$final_path" # chown -R $app:www-data "$final_path" -dir='__DIR__' -ynh_add_config --template="../conf/config-dist.php" --destination="$final_path/config.php" -chmod 400 "$final_path/config.php" -chown $app:$app "$final_path/config.php" +# dir='__DIR__' +# ynh_add_config --template="../conf/config-dist.php" --destination="$final_path/config.php" + +# chmod 400 "$final_path/config.php" +# chown $app:$app "$final_path/config.php" #================================================= # RELOAD NGINX