move x-accel into local storage configuration
This commit is contained in:
45
config.yaml
45
config.yaml
@ -88,21 +88,21 @@ upstream:
|
||||
allowed-redirect: "^https?://cf-builds.garudalinux.org/.*/chaotic-aur/.*$"
|
||||
|
||||
misc:
|
||||
first-chunk-bytes: 31457280 # 1024*1024*30, all upstreams with 200 response will wait for the first chunks to select a upstream by bandwidth, instead of by latency. defaults to 50M
|
||||
# chunk-bytes: 1048576 # 1024*1024
|
||||
first-chunk-bytes: 31457280 ## 1024*1024*30, all upstreams with 200 response will wait for the first chunks to select a upstream by bandwidth, instead of by latency. defaults to 50M
|
||||
# chunk-bytes: 1048576 ## 1024*1024
|
||||
|
||||
cache:
|
||||
timeout: 1h
|
||||
policies:
|
||||
- match: '.*\.(rpm|deb|apk|iso)$' # rpm/deb/apk/iso won't change, create only
|
||||
- match: '.*\.(rpm|deb|apk|iso)$' ## rpm/deb/apk/iso won't change, create only
|
||||
refresh-after: never
|
||||
- match: '^/.*-security/.*' # mostly ubuntu/debian security
|
||||
- match: '^/.*-security/.*' ## mostly ubuntu/debian security
|
||||
refresh-after: 1h
|
||||
- match: '^/archlinux-localaur/.*' # archlinux local repo
|
||||
- match: '^/archlinux-localaur/.*' ## archlinux local repo
|
||||
refresh-after: never
|
||||
- match: '^/(archlinux.*|chaotic-aur)/*.tar.*' # archlinux packages
|
||||
- match: '^/(archlinux.*|chaotic-aur)/*.tar.*' ## archlinux packages
|
||||
refresh-after: never
|
||||
- match: '/chaotic-aur/.*\.db$' # archlinux chaotic-aur database
|
||||
- match: '/chaotic-aur/.*\.db$' ## archlinux chaotic-aur database
|
||||
refresh-after: 24h
|
||||
- match: '/centos/7'
|
||||
refresh-after: never
|
||||
@ -110,20 +110,23 @@ cache:
|
||||
refresh-after: never
|
||||
|
||||
storage:
|
||||
type: local # ignored
|
||||
type: local ## ignored for now
|
||||
local:
|
||||
path: ./data # defaults to ./data
|
||||
path: ./data ## defaults to ./data
|
||||
|
||||
accel:
|
||||
# example nginx config:
|
||||
## location /i {
|
||||
## internal;
|
||||
## alias /path/to/data;
|
||||
## }
|
||||
## location / {
|
||||
## proxy_pass 127.0.0.1:8881;
|
||||
## proxy_set_header X-Accel-Path /i;
|
||||
## }
|
||||
##
|
||||
accel:
|
||||
## example nginx config:
|
||||
## location /i {
|
||||
## internal;
|
||||
## alias /path/to/data;
|
||||
## }
|
||||
## location / {
|
||||
## proxy_pass 127.0.0.1:8881;
|
||||
## proxy_set_header X-Accel-Path /i;
|
||||
## }
|
||||
##
|
||||
## then cache proxy will respond to backend a header to indicate sendfile(join(X-Accel-Path, relpath))
|
||||
# enable-by-header: "X-Accel-Path"
|
||||
|
||||
# enable-by-header: "X-Accel-Path"
|
||||
## respond with different headers to
|
||||
# respond-with-headers: [X-Sendfile, X-Accel-Redirect]
|
||||
|
Reference in New Issue
Block a user