mirror of
https://pagure.io/fedora-infra/ansible.git
synced 2026-03-20 03:57:02 +08:00
copr/anubis: fix configuration on frontend to protect only /coprs (same for distgit)
Anubis was accidentally enabled for all traffic (/) instead of just
the /coprs/ web UI. This caused unnecessary bot challenges for API
clients, dnf/yum, and other automated tools.
Use Anubis BASE_PREFIX to cleanly protect only specific endpoints:
- Frontend: /coprs/ (web UI)
- Dist-git: /{{ cgit_uri }}/ (package browser)
https://anubis.techaro.lol/docs/admin/installation#using-base-prefix
This commit is contained in:
@@ -85,8 +85,13 @@ WSGIApplicationGroup %{GLOBAL}
|
||||
ProxyRequests Off
|
||||
ProxyVia Off
|
||||
|
||||
ProxyPass / http://127.0.0.1:8987/
|
||||
ProxyPassReverse / http://127.0.0.1:8987/
|
||||
# /coprs/ goes through Anubis (configured with BASE_PREFIX=/coprs)
|
||||
ProxyPass /coprs/ http://127.0.0.1:8987/coprs/
|
||||
ProxyPassReverse /coprs/ http://127.0.0.1:8987/coprs/
|
||||
|
||||
# Everything else goes directly to backend
|
||||
ProxyPass / http://127.0.0.1:8345/
|
||||
ProxyPassReverse / http://127.0.0.1:8345/
|
||||
</VirtualHost>
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user