Hi,

you could use a map that matches all cases to empty string and default
value as non-empty

map $arg_capacity $my_default_key{~*([2-9]|10)X ""; default
$http_x_forwarded_for;}

If it matches 2X to 10X, $my_default_key will be empty.

Cheers
Jader H. Silva


2013/10/25 Brian08275660 <nginx-fo...@nginx.us>

> Hi Francis,
>
> Now I need to create a limit that acts if the parameter ("capacity") is
> empty (not provided). How do I do that? I can't find how to, at least not
> using "map".
> (If provided, the other rules will evaluate it and one of them will act
> according to the value).
>
> Thanks in advanced!
>
> Posted at Nginx Forum:
> http://forum.nginx.org/read.php?2,244015,244123#msg-244123
>
> _______________________________________________
> nginx mailing list
> nginx@nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
>
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx

Reply via email to