mirror of
https://github.com/YunoHost-Apps/garage_ynh.git
synced 2024-09-03 18:36:32 +02:00
Apply nginx workaround for upgrade too
This commit is contained in:
parent
4974d91302
commit
53cecfdff5
2 changed files with 17 additions and 0 deletions
|
@ -23,6 +23,15 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd"
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Updating NGINX web server configuration..." --weight=1
|
ynh_script_progression --message="Updating NGINX web server configuration..." --weight=1
|
||||||
|
|
||||||
|
if [[ "${PACKAGE_CHECK_EXEC:-}" -eq 1 ]]
|
||||||
|
then
|
||||||
|
cat << EOF > ../conf/nginx.conf
|
||||||
|
location / {
|
||||||
|
return 200 'This is a dummy page for garage, only displayed during tests on Yunohost CI';
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
ynh_change_url_nginx_config
|
ynh_change_url_nginx_config
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -45,6 +45,14 @@ chown -R $app:$app "$install_dir"
|
||||||
ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=1
|
ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=1
|
||||||
|
|
||||||
# Create a dedicated NGINX config
|
# Create a dedicated NGINX config
|
||||||
|
if [[ "${PACKAGE_CHECK_EXEC:-}" -eq 1 ]]
|
||||||
|
then
|
||||||
|
cat << EOF > ../conf/nginx.conf
|
||||||
|
location / {
|
||||||
|
return 200 'This is a dummy page for garage, only displayed during tests on Yunohost CI';
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
ynh_add_nginx_config
|
ynh_add_nginx_config
|
||||||
|
|
||||||
ynh_add_config --template="regenconf_nginx_garage" --destination="/usr/share/yunohost/hooks/conf_regen/98-nginx_$app"
|
ynh_add_config --template="regenconf_nginx_garage" --destination="/usr/share/yunohost/hooks/conf_regen/98-nginx_$app"
|
||||||
|
|
Loading…
Add table
Reference in a new issue