Update the On/Off error code parameter
Revert nginx config
This commit is contained in:
parent
42a5b89393
commit
1b4c09bc1d
2 changed files with 9 additions and 6 deletions
|
@ -6,8 +6,7 @@ location __PATH__/ {
|
||||||
|
|
||||||
# Default indexes and catch-all
|
# Default indexes and catch-all
|
||||||
index index.html index.php;
|
index index.html index.php;
|
||||||
# try_files $uri $uri/ __PATH__/index.php?$args =404;
|
try_files $uri $uri/ __PATH__/index.php?$args =404;
|
||||||
try_files $uri $uri/ __PATH__/index.php?$args;
|
|
||||||
|
|
||||||
# Prevent useless logs
|
# Prevent useless logs
|
||||||
location = __PATH__/favicon.ico {
|
location = __PATH__/favicon.ico {
|
||||||
|
|
|
@ -151,10 +151,14 @@ ynh_app_config_apply() {
|
||||||
if [ "${changed[custom_error_file]}" == "true" ]
|
if [ "${changed[custom_error_file]}" == "true" ]
|
||||||
then
|
then
|
||||||
CUSTOM_ERROR_FILE=$custom_error_file
|
CUSTOM_ERROR_FILE=$custom_error_file
|
||||||
# ynh_add_config --template="nginx-code-error.conf" --destination="/etc/nginx/conf.d/$domain.d/$app.d/error-code.conf"
|
nginx_extra_conf_dir="/etc/nginx/conf.d/$domain.d/$app.d"
|
||||||
ynh_secure_remove --file="/etc/nginx/conf.d/$domain.d/$app.d/error-code.conf"
|
|
||||||
else
|
if [ "$custom_error_file" ]
|
||||||
ynh_secure_remove --file="/etc/nginx/conf.d/$domain.d/$app.d/error-code.conf"
|
then
|
||||||
|
ynh_add_config --template="nginx-code-error.conf" --destination="$nginx_extra_conf_dir/error-code.conf"
|
||||||
|
else
|
||||||
|
ynh_secure_remove --file="$nginx_extra_conf_dir/error-code.conf"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$phpversion" != "none" ]
|
if [ "$phpversion" != "none" ]
|
||||||
|
|
Loading…
Add table
Reference in a new issue