Ticket #974 (new enhancement)

Opened 2 years ago

would like something similar to nginx proxy_intercept_errors

Reported by: yusufg Assigned to: jan
Priority: normal Milestone:
Component: core Version: 1.5.x-svn
Severity: normal Keywords:
Cc: Blocking:
Need Feedback:

Description

nginx has a neat feature in which it can intercept responses with HTTP status code of 400 and higher

http://wiki.codemongers.com/NginxHttpProxyModule#proxy_intercept_errors

The error page handler allows one to change the response status code also

http://wiki.codemongers.com/NginxHttpCoreModule#error_page

here's how one would would redirect 4xx/5xx responses from backend

error_page 401 402 404 /40x.html;

location /40x.html {

root /errors/ ;

}

error_page 502 503 504 /50x.html;

location /50x.html {

root /errors/ ;

}

upstream backend {

server backend2.example.com:8080;

} location / {

proxy_intercept_errors on; proxy_pass backend

}

Attachments


Add/Change #974 (would like something similar to nginx proxy_intercept_errors)




Change Properties