mirror of
https://github.com/WJQSERVER-STUDIO/ghproxy.git
synced 2026-02-03 08:11:11 +08:00
v1.1.1
This commit is contained in:
parent
df05c6a275
commit
9f801bbac8
5 changed files with 24 additions and 12 deletions
|
|
@ -4,7 +4,7 @@
|
|||
https_port 443
|
||||
order cache before rewrite
|
||||
cache {
|
||||
cache_name W-Cache
|
||||
cache_name GhProxyCache
|
||||
}
|
||||
log {
|
||||
level INFO
|
||||
|
|
@ -20,7 +20,7 @@
|
|||
format transform `{request>headers>X-Forwarded-For>[0]:request>remote_ip} - {user_id} [{ts}] "{request>method} {request>uri} {request>proto}" {status} {size} "{request>headers>Referer>[0]}" "{request>headers>User-Agent>[0]}"` {
|
||||
time_format "02/Jan/2006:15:04:05 -0700"
|
||||
}
|
||||
output file /data/caddy/log/{args.0}/access.log {
|
||||
output file /data/caddy/log/{args[0]}/access.log {
|
||||
roll_size 5MB
|
||||
roll_keep 10
|
||||
roll_keep_for 24h
|
||||
|
|
@ -48,8 +48,8 @@
|
|||
(cache) {
|
||||
cache {
|
||||
allowed_http_verbs GET
|
||||
stale {args.0}
|
||||
ttl {args.1}
|
||||
stale {args[0]}
|
||||
ttl {args[1]}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -68,7 +68,7 @@
|
|||
|
||||
(rate_limit) {
|
||||
route /* {
|
||||
rate_limit {remote.ip} {args.0}r/m 10000 429
|
||||
rate_limit {remote.ip} {args[0]}r/m 10000 429
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue