Feature request: Decouple proxy_intercept_errors from custom-http-errors #9211
Labels
kind/feature
Categorizes issue or PR as related to a new feature.
needs-priority
needs-triage
Indicates an issue or PR lacks a `triage/foo` label and requires one.
We're using external auth and would like to serve custom error pages to our users if external auth doesn't allow the request through.
We'd like to do this while letting the protected upstream services return their own error pages.
Here's the snippet for the error handling on locations
You can't set customHttpErrors without also intercepting all errors. Note that the external auth subrequest apparently doesn't rely on proxy_intercept_errors but uses any defined error_page if available. This is how external auth signin url works.
Is there another way to define an error page for the failure responses of external auth (401, 403, 500) without intercepting the errors of the upstream services?
Currently it looks like our only option is to overwrite the nginx template.
So our proposed feature request: By default errors should be intercepted if you specify custom http errors, but you should be able to override that using something like
nginx.ingress.kubernetes.io/proxy-intercept-errors: "off"
The text was updated successfully, but these errors were encountered: