Skip to content

Commit 895b19c

Browse files
author
Kristan Kenney
committed
Update error page directives
1 parent 22520bc commit 895b19c

File tree

4 files changed

+21
-17
lines changed

4 files changed

+21
-17
lines changed

install/deb/templates/mail/nginx/default.stpl

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,16 +47,17 @@ server {
4747
fastcgi_param HTTPS on;
4848
}
4949

50-
location @fallback {
51-
proxy_pass http://%ip%:%web_port%;
52-
}
53-
5450
error_page 403 /error/404.html;
5551
error_page 404 /error/404.html;
56-
error_page 500 502 503 504 /error/50x.html;
57-
52+
error_page 500 502 503 504 505 /error/50x.html;
53+
5854
location /error/ {
59-
alias /var/www/document_errors/;
55+
alias /var/www/document_errors/;
56+
try_files $uri $uri/;
57+
}
58+
59+
location @fallback {
60+
proxy_pass http://%ip%:%web_port%;
6061
}
6162

6263
include %home%/%user%/conf/mail/%root_domain%/%proxy_system%.conf_*;

install/deb/templates/mail/nginx/default.tpl

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,16 +46,17 @@ server {
4646
fastcgi_param SCRIPT_FILENAME $request_filename;
4747
}
4848

49-
location @fallback {
50-
proxy_pass http://%ip%:%web_port%;
51-
}
52-
5349
error_page 403 /error/404.html;
5450
error_page 404 /error/404.html;
55-
error_page 500 502 503 504 /error/50x.html;
51+
error_page 500 502 503 504 505 /error/50x.html;
5652

5753
location /error/ {
58-
alias /var/www/document_errors/;
54+
alias /var/www/document_errors/;
55+
try_files $uri $uri/;
56+
}
57+
58+
location @fallback {
59+
proxy_pass http://%ip%:%web_port%;
5960
}
6061

6162
include %home%/%user%/conf/mail/%root_domain%/%proxy_system%.conf_*;

install/deb/templates/mail/nginx/web_system.stpl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,11 @@ server {
5151

5252
error_page 403 /error/404.html;
5353
error_page 404 /error/404.html;
54-
error_page 500 502 503 504 /error/50x.html;
54+
error_page 500 502 503 504 505 /error/50x.html;
5555

5656
location /error/ {
57-
alias /var/www/document_errors/;
57+
alias /var/www/document_errors/;
58+
try_files $uri $uri/;
5859
}
5960

6061
include %home%/%user%/conf/mail/%root_domain%/%web_system%.conf_*;

install/deb/templates/mail/nginx/web_system.tpl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,11 @@ server {
5050

5151
error_page 403 /error/404.html;
5252
error_page 404 /error/404.html;
53-
error_page 500 502 503 504 /error/50x.html;
53+
error_page 500 502 503 504 505 /error/50x.html;
5454

5555
location /error/ {
56-
alias /var/www/document_errors/;
56+
alias /var/www/document_errors/;
57+
try_files $uri $uri/;
5758
}
5859

5960
include %home%/%user%/conf/mail/%root_domain%/%web_system%.conf_*;

0 commit comments

Comments
 (0)