3-tier implementation of manifest caching (#57)
* implement manifest caching; refactor config with includes, and generate from ENVs in entrypoint.sh - disabled by default; enable with -e ENABLE_MANIFEST_CACHE=true - default times and regexes are a wild guess, make sure to tune for your use case. - add manifest caching/anti-ratelimit usage note to README - add -e ENABLE_MANIFEST_CACHE=true to examples, some wording changes - add -e ENABLE_MANIFEST_CACHE=true to one the steps in test workflow.
This commit is contained in:
8
nginx.manifest.common.conf
Normal file
8
nginx.manifest.common.conf
Normal file
@@ -0,0 +1,8 @@
|
||||
# nginx config fragment included in every manifest-related location{} block.
|
||||
add_header X-Docker-Registry-Proxy-Cache-Upstream-Status "$upstream_cache_status";
|
||||
add_header X-Docker-Registry-Proxy-Cache-Type "$docker_proxy_request_type";
|
||||
proxy_pass https://$targetHost;
|
||||
proxy_cache cache;
|
||||
proxy_cache_key $uri;
|
||||
proxy_intercept_errors on;
|
||||
error_page 301 302 307 = @handle_redirects;
|
||||
Reference in New Issue
Block a user