diff --git a/check_process b/check_process index 9e0b364..067a029 100644 --- a/check_process +++ b/check_process @@ -28,7 +28,7 @@ backup_restore=1 multi_instance=1 port_already_use=1 (66) - change_url=0 + change_url=1 actions=0 config_panel=0 ;;; Levels diff --git a/scripts/change_url b/scripts/change_url index b594211..3efbe2b 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -91,10 +91,10 @@ fi # Change the domain for nginx if [ $change_domain -eq 1 ] then - # Delete file checksum for the old conf file location + # Delete file checksum for the old conf file location ynh_delete_file_checksum --file="$nginx_conf_path" mv $nginx_conf_path /etc/nginx/conf.d/$new_domain.d/$app.conf - # Store file checksum for the new config file location + # Store file checksum for the new config file location ynh_store_file_checksum --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" fi @@ -104,6 +104,8 @@ fi # ... #================================================= +ynh_replace_string --match_string="https://$old_domain${old_path%/}" --replace_string="https://$new_domain${new_path%/}" --target_file="$final_path/wakka.config.php" + #================================================= # GENERIC FINALISATION #================================================= @@ -117,4 +119,4 @@ ynh_systemd_action --service_name=nginx --action=reload # END OF SCRIPT #================================================= -ynh_script_progression --message="Change of URL completed for $app" --last +ynh_script_progression --message="Change of URL completed for $app" --last