Skip to content

Instantly share code, notes, and snippets.

Last active Sep 27, 2021
What would you like to do?
Nginx Reverse Proxy with custom error if upstream proxy is not working.
server {
listen 80;
listen [::]:80 default server ipv6only=on;
location / {
proxy_intercept_errors on;
proxy_pass http://localhost:9000;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /var/www/errors;

This comment has been minimized.

Copy link

@thisis2394 thisis2394 commented Jul 27, 2021

Thanks for sharing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment