Skip to content

Commit

Permalink
Temporarily disable request and connection limits.
Browse files Browse the repository at this point in the history
  • Loading branch information
dokterbob committed Dec 28, 2022
1 parent 315e662 commit a5b7659
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions roles/services/frontend/templates/nginx-frontend.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ proxy_cache_path {{ frontend_cache_path }}/thumbnail levels=1:2 keys_zone=thumbn
# Allow hole-punching in proxy with `?nocache=true`.
proxy_cache_bypass $cookie_nocache $arg_nocache;

# TODO: Whitelist for load testing.
# https://gadelkareem.com/2012/03/25/limit-requests-per-ip-on-nginx-using-httplimitzonemodule-and-httplimitreqmodule-except-whitelist/
limit_req_zone $binary_remote_addr zone=search_reqs:10m rate=200r/s;
limit_conn_zone $binary_remote_addr zone=search_conns:10m;

Expand Down Expand Up @@ -83,8 +85,8 @@ server {

server_name {{ api_server_name }};

limit_req zone=search_reqs burst=300;
limit_conn search_conns 200; # Concurrent requests per client IP.
# limit_req zone=search_reqs burst=300;
# limit_conn search_conns 200; # Concurrent requests per client IP.

location / {
return 301 https://app.swaggerhub.com/apis-docs/ipfs-search/ipfs-search;
Expand Down

0 comments on commit a5b7659

Please sign in to comment.