Welcome! Log In Create A New Profile

Advanced

Nginx 404 showing when I configured for a custom 404 page

Quintin Par
May 17, 2012 07:36PM
Hi all,

I have a 404 custom page set like this

error_page 404 = @errorpages;

error_page 500 = @errorpages;



location @errorpages {

root /var/www/;

internal;

proxy_pass http://localhost:82;

proxy_set_header Host $host;

proxy_set_header X-Real-IP $remote_addr;

proxy_set_header Accept-Encoding "";

proxy_ignore_headers Set-Cookie;

proxy_ignore_headers Cache-Control;

proxy_ignore_headers Expires;

proxy_ignore_headers X-Accel-Expires;

add_header X-Cache-Status $upstream_cache_status;

proxy_cache cache;

proxy_cache_key $request_uri;

proxy_cache_use_stale updating;

}

But every now and then I am hitting the nginx vanilla 404 pages, especially
when hitting rate limiting.

How do I close the gaps to ensure I am showing only the custom 404’s ?

- Quintin
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Nginx 404 showing when I configured for a custom 404 page

Quintin Par May 17, 2012 07:36PM

Re: Nginx 404 showing when I configured for a custom 404 page

Maxim Dounin May 18, 2012 05:50AM

Re: Nginx 404 showing when I configured for a custom 404 page

Quintin Par May 31, 2012 07:18PM

Re: Nginx 404 showing when I configured for a custom 404 page

Quintin Par June 23, 2012 12:12PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 158
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready