Enable proxying of copr api_2 and api_3
This commit is contained in:
parent
0a67a43d54
commit
735d10275c
3 changed files with 5 additions and 7 deletions
|
@ -33,9 +33,6 @@
|
|||
- role: httpd/reverseproxy
|
||||
website: copr.fedoraproject.org
|
||||
destname: coprapi
|
||||
localpath: /api
|
||||
remotepath: /api
|
||||
proxyurl: https://copr.fedorainfracloud.org
|
||||
when: env != "staging"
|
||||
tags: copr
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
RewriteEngine on
|
||||
RewriteCond %{REQUEST_URI} !^/api/*
|
||||
RewriteCond %{REQUEST_URI} !^/api_2/*
|
||||
RewriteCond %{REQUEST_URI} !^/api
|
||||
RewriteRule ^/(.*) https://copr.fedorainfracloud.org/$1 [L,R]
|
||||
|
|
|
@ -11,5 +11,7 @@ RequestHeader set X-Scheme https early
|
|||
RequestHeader set X-Forwarded-Proto https early
|
||||
|
||||
{% endif %}
|
||||
ProxyPass {{ localpath }} {{ proxyurl }}{{remotepath}}
|
||||
ProxyPassReverse {{ localpath }} {{ proxyurl }}{{remotepath}}
|
||||
{% for path in ('api', 'api_2', 'api_3') %}
|
||||
ProxyPass /{{path}} https://copr.fedorainfracloud.org/{{path}}
|
||||
ProxyPassReverse /{{path}} https://copr.fedorainfracloud.org/{{path}}
|
||||
{% endfor %}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue