mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-04-29 10:10:19 +00:00
- Avoid Satisfy and Allow which are deprecated. - Make sure the redirection rule applies only to the URL intended. - Fix issue with Proxy matching of URLs. Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
27 lines
755 B
Plaintext
27 lines
755 B
Plaintext
# Redirect /searx to /searx/
|
|
<Location ~ ^/searx$>
|
|
<IfModule mod_rewrite.c>
|
|
RewriteEngine On
|
|
RewriteCond %{REQUEST_URI} ^/searx$
|
|
RewriteRule .* /searx/ [R=301,L]
|
|
</IfModule>
|
|
</Location>
|
|
|
|
|
|
<Location /searx/>
|
|
Include includes/freedombox-single-sign-on.conf
|
|
|
|
<IfModule mod_auth_pubtkt.c>
|
|
TKTAuthToken "web-search" "admin"
|
|
</IfModule>
|
|
|
|
ProxyPass unix:/run/uwsgi/app/searx/socket|uwsgi://uwsgi-uds-searx/
|
|
</Location>
|
|
|
|
|
|
# This exclusion rule is to allow Searx to be added as a search engine in Firefox.
|
|
<LocationMatch "^/searx/(opensearch.xml|static/themes/oscar/img/favicon.png)$">
|
|
Require all granted
|
|
ProxyPassMatch "unix:/run/uwsgi/app/searx/socket|uwsgi://uwsgi-uds-searx/$1"
|
|
</LocationMatch>
|