FreedomBox/data/etc/apache2/conf-available/searx-freedombox.conf
Joseph Nuthalapati c03f92a407
searx: Rewrite url from /searx to /searx/
Signed-off-by: Joseph Nuthalapati <njoseph@thoughtworks.com>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2018-03-20 21:45:11 -04:00

29 lines
771 B
Plaintext

# 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)$">
Satisfy Any
Allow from all
AuthType None
ProxyPass unix:/run/uwsgi/app/searx/socket|uwsgi://uwsgi-uds-searx/
</LocationMatch>
# 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>