mirror of
https://github.com/PokeAPI/pokeapi
synced 2024-11-13 23:37:06 +00:00
feat: comment out throttling
This commit is contained in:
parent
3d116fef9c
commit
ef7b165704
2 changed files with 8 additions and 8 deletions
|
@ -38,7 +38,7 @@ http {
|
||||||
server app:8000 fail_timeout=0;
|
server app:8000 fail_timeout=0;
|
||||||
}
|
}
|
||||||
|
|
||||||
limit_req_zone $binary_remote_addr zone=api:10m rate=2r/s;
|
# limit_req_zone $binary_remote_addr zone=api:10m rate=2r/s;
|
||||||
|
|
||||||
server {
|
server {
|
||||||
listen 80 deferred;
|
listen 80 deferred;
|
||||||
|
@ -72,7 +72,7 @@ http {
|
||||||
add_header Cache-Control "public";
|
add_header Cache-Control "public";
|
||||||
add_header Pragma public;
|
add_header Pragma public;
|
||||||
|
|
||||||
limit_req zone=api burst=10;
|
# limit_req zone=api burst=10;
|
||||||
|
|
||||||
proxy_set_header X-Real-IP $remote_addr;
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
|
|
@ -127,10 +127,10 @@ REST_FRAMEWORK = {
|
||||||
'PAGE_SIZE': 20,
|
'PAGE_SIZE': 20,
|
||||||
|
|
||||||
'PAGINATE_BY': 20,
|
'PAGINATE_BY': 20,
|
||||||
'DEFAULT_THROTTLE_CLASSES': (
|
# 'DEFAULT_THROTTLE_CLASSES': (
|
||||||
'rest_framework.throttling.AnonRateThrottle',
|
# 'rest_framework.throttling.AnonRateThrottle',
|
||||||
),
|
# ),
|
||||||
'DEFAULT_THROTTLE_RATES': {
|
# 'DEFAULT_THROTTLE_RATES': {
|
||||||
'anon': '1000/hour'
|
# 'anon': '1000/hour'
|
||||||
}
|
# }
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue