debuginfod: balance redirect & reverse-proxy better
Our ansible default ansible scripts don't like multiple /suburls being individually proxied, so we ended up losing /buildid/* and keeping /metrics. Switch to using single /-level reverse-proxying AND wiki-redirection clauses, and use a new template .conf file to break the tie with a "ProxyPass / !" directive.
This commit is contained in:
parent
6b7b396979
commit
ab51e82014
3 changed files with 15 additions and 22 deletions
|
@ -873,7 +873,7 @@
|
||||||
path: /
|
path: /
|
||||||
target: https://fedoraproject.org/wiki/QA
|
target: https://fedoraproject.org/wiki/QA
|
||||||
|
|
||||||
# redirects for debuginfod main page
|
# redirects for debuginfod main page; subdirs are reverse-proxied
|
||||||
- role: httpd/redirect
|
- role: httpd/redirect
|
||||||
shortname: debuginfod
|
shortname: debuginfod
|
||||||
website: debuginfod.fedoraproject.org
|
website: debuginfod.fedoraproject.org
|
||||||
|
@ -882,10 +882,3 @@
|
||||||
tags:
|
tags:
|
||||||
- debuginfod
|
- debuginfod
|
||||||
|
|
||||||
- role: httpd/redirect
|
|
||||||
shortname: debuginfod
|
|
||||||
website: debuginfod.fedoraproject.org
|
|
||||||
regex: ^/index.html$
|
|
||||||
target: https://fedoraproject.org/wiki/Debuginfod
|
|
||||||
tags:
|
|
||||||
- debuginfod
|
|
||||||
|
|
|
@ -751,18 +751,8 @@
|
||||||
- role: httpd/reverseproxy
|
- role: httpd/reverseproxy
|
||||||
website: debuginfod.fedoraproject.org
|
website: debuginfod.fedoraproject.org
|
||||||
destname: debuginfod
|
destname: debuginfod
|
||||||
remotepath: /buildid/
|
# manage non-trivial reverse-proxy specs in template
|
||||||
localpath: /buildid/
|
|
||||||
proxyurl: http://debuginfod01:8002
|
proxyurl: http://debuginfod01:8002
|
||||||
proxyopts: "connectiontimeout=600 timeout=600 keepalive=on"
|
proxyopts: "connectiontimeout=600 timeout=600 keepalive=on"
|
||||||
tags: debuginfod
|
tags:
|
||||||
|
- debuginfod
|
||||||
- role: httpd/reverseproxy
|
|
||||||
website: debuginfod.fedoraproject.org
|
|
||||||
destname: debuginfod
|
|
||||||
remotepath: /metrics
|
|
||||||
localpath: /metrics
|
|
||||||
proxyurl: http://debuginfod01:8002
|
|
||||||
proxyopts: "connectiontimeout=600 timeout=600 keepalive=on"
|
|
||||||
tags: debuginfod
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,10 @@
|
||||||
|
|
||||||
|
# Broadly reverse-proxy
|
||||||
|
ProxyPassMatch "^(.*)$" "{{proxyurl}}$1" {{proxyopts}}
|
||||||
|
ProxyPassReverse / {{proxyurl}}/
|
||||||
|
|
||||||
|
# ... but not the top level, which is instead redirected
|
||||||
|
ProxyPass / !
|
||||||
|
|
||||||
|
# ... configure this redirect in playbooks/include/proxies-redirects.yml
|
||||||
|
# Redirect permanent / https://sourceware.org/elfutils/Debuginfod.html
|
Loading…
Add table
Add a link
Reference in a new issue