2024-01-01 23:59:26 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
source _common.sh
|
|
|
|
source /usr/share/yunohost/helpers
|
|
|
|
|
|
|
|
#=================================================
|
|
|
|
# MODIFY URL IN NGINX CONF
|
|
|
|
#=================================================
|
2024-08-30 22:55:10 +02:00
|
|
|
ynh_script_progression "Updating NGINX web server configuration..."
|
2024-01-01 23:59:26 +01:00
|
|
|
|
2024-08-30 22:55:10 +02:00
|
|
|
ynh_config_change_url_nginx
|
2024-01-01 23:59:26 +01:00
|
|
|
|
|
|
|
#=================================================
|
|
|
|
# SPECIFIC MODIFICATIONS
|
|
|
|
#=================================================
|
|
|
|
|
2024-01-25 23:16:00 +01:00
|
|
|
path_without_trailing_slash=${path%/}
|
2024-08-30 22:55:10 +02:00
|
|
|
ynh_replace --match="<base href=".*">" --replace="<base href=\"$path_without_trailing_slash/\">" --file="$install_dir/index.html"
|
2024-01-01 23:59:26 +01:00
|
|
|
|
|
|
|
#=================================================
|
|
|
|
# END OF SCRIPT
|
|
|
|
#=================================================
|
|
|
|
|
2024-08-30 22:55:10 +02:00
|
|
|
ynh_script_progression "Change of URL completed for $app"
|