kuberxy opened a new issue #3114:
URL: https://github.com/apache/apisix/issues/3114
我想对来自于公网的所有请求进行限速,但来自内网的请求不限速,该如何配置?
我尝试的配置如下:
apisix.yaml:
```yaml
plugins:
- name: limit-req
global_rules:
-
id: 1
plugins:
limit-req:
rate: 10
burst: 0
rejected_code: 503
key: "remote_addr"
upstreams:
-
id: 1
name: "nginx"
nodes:
"192.168.3.146:8080": 1
type: roundrobin
checks:
active:
http_path: "/"
healthy:
interval: 2
successes: 1
routes:
-
uri: /*
upstream_id: 1
-
remote_addr: "192.168.3.26"
uri: /*
plugins:
limit-req:
rate: 1000
burst: 0
rejected_code: 429
key: "remote_addr"
priority: 10
#END
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]