1
0

Улучшен конфиг для 404

This commit is contained in:
Anton Vakhrushev 2018-09-14 07:44:58 +03:00
parent daae31c044
commit 98c519a17f

View File

@ -23,18 +23,17 @@ server {
ssl_dhparam {{ vars[homepage_name + "_ssl_dhparam"] }}; ssl_dhparam {{ vars[homepage_name + "_ssl_dhparam"] }};
ssl_prefer_server_ciphers on; ssl_prefer_server_ciphers on;
root {{ homepage_dir }}/current;
index index.html;
error_page 404 = @notfound;
location / { location / {
root {{ homepage_dir }}/current;
index index.html;
try_files $uri $uri/ =404; try_files $uri $uri/ =404;
} }
error_page 404 /404/; location @notfound {
try_files /404/index.html =409;
location = /404/ {
root {{ homepage_dir }}/current;
index index.html;
try_files $uri $uri/ =409;
internal; internal;
} }
} }