Skip to content

Commit 8e89a80

Browse files
authored
Merge pull request #147 from psaux-it/preload-progress
exclude preload-progress from API rate limit
2 parents 17901f3 + 20be0da commit 8e89a80

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

nginx/nginx.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,13 +178,13 @@ http {
178178
XMLHttpRequest 1;
179179
}
180180

181-
######## NPP API RATE LIMIT ########
181+
######## NPP REST API RATE LIMIT ########
182182

183183
# Limits requests to the NPP cache API endpoint.
184184
# Only active for matching URIs; all other requests use an empty key
185185
# which disables rate limiting entirely for non-NPP traffic.
186186
map $request_uri $nppp_limit_key {
187-
~^/wp-json/nppp_nginx_cache/ $binary_remote_addr;
187+
~^/wp-json/nppp_nginx_cache/v2/(purge|preload)(\?.*)?$ $binary_remote_addr;
188188
default "";
189189
}
190190
limit_req_zone $nppp_limit_key zone=nppp_api:10m rate=10r/m;

0 commit comments

Comments
 (0)