From 763515267bc7e5fa1ccceab6a5320bec1833b31d Mon Sep 17 00:00:00 2001 From: Ricardo Pardini Date: Fri, 30 Oct 2020 01:29:13 +0100 Subject: [PATCH] use_stale for HTTP 429 Too Many Requests (actually used by DockerHub ratelimiting #54) instead of 403 - tested by trying to pull `ratelimitalways/test:latest` --- nginx.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nginx.conf b/nginx.conf index 0183ca5..489bc8c 100644 --- a/nginx.conf +++ b/nginx.conf @@ -288,7 +288,7 @@ echo "Docker configured with HTTPS_PROXY=$scheme://$http_host/" proxy_cache cache; proxy_cache_key $uri; proxy_intercept_errors on; - proxy_cache_use_stale error timeout http_500 http_502 http_504 http_403; + proxy_cache_use_stale error timeout http_500 http_502 http_504 http_429; proxy_cache_valid 1s; error_page 301 302 307 = @handle_redirects; } @@ -300,7 +300,7 @@ echo "Docker configured with HTTPS_PROXY=$scheme://$http_host/" proxy_cache cache; proxy_cache_key $uri; proxy_intercept_errors on; - proxy_cache_use_stale error timeout http_500 http_502 http_504 http_403; + proxy_cache_use_stale error timeout http_500 http_502 http_504 http_429; proxy_cache_valid 1s; error_page 301 302 307 = @handle_redirects; }