【发布时间】:2018-02-22 14:35:58
【问题描述】:
我的 nginx.conf 中针对主机和 IP 设置了全局速率限制。但是,有一个特定位置我想忽略这些限制,就像这样。
limit_req_zone $binary_remote_addr zone=limitip:10m rate=10r/s;
limit_req_zone $host zone=limithost:10m rate=10r/s;
server {
limit_req zone=limitip burst=5 nodelay;
limit_req zone=limithost burst=5 nodelay;
location /whitelisted_location {
/* ignore the server limits */
}
}
创建两个具有非常高价值的新区域并在该位置内使用它们的最佳方法是什么?
【问题讨论】:
标签: nginx rate-limiting