Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fbd41004 authored by Arnau Vàzquez's avatar Arnau Vàzquez
Browse files

Merge branch 'fix-limits-nginx' into 'master'

remove limits in nginx to prevent overlapping with filtron

Closes backlog#768 and backlog#771

See merge request !136
parents 1cae222d 244e730f
Loading
Loading
Loading
Loading
+0 −14
Original line number Diff line number Diff line
geo $limit {
    default 1;
    5.9.58.49 0;
}

map $limit $limit_key {
    0 "";
    1 $http_x_forwarded_for;
}

limit_req_zone $limit_key zone=botlimit:10m rate=10r/s;

server {
  listen 80;
  server_name _;
@@ -21,11 +9,9 @@ server {
  root /var/www/spot;

  location = / {
    limit_req zone=botlimit burst=10;
    include /etc/nginx/proxy_spot_params;
  }
  location = /search {
    limit_req zone=botlimit burst=10;
    include /etc/nginx/proxy_spot_params;
  }
  location / {