Update SearXNG configuration in Caddyfile

- Implemented IP-based access control for basic authentication in the SearXNG section.
- Enhanced security by restricting access to specific IP ranges while maintaining authentication for other users.
This commit is contained in:
Yury Kossakovsky
2025-06-28 16:03:58 -06:00
parent 215fe644a2
commit 32a673d8f4

View File

@@ -77,7 +77,9 @@ import /etc/caddy/addons/*.conf
# # SearXNG
{$SEARXNG_HOSTNAME} {
basic_auth {
@protected not remote_ip 127.0.0.0/8 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 100.64.0.0/10
basic_auth @protected {
{$SEARXNG_USERNAME} {$SEARXNG_PASSWORD_HASH}
}