Open-source LLM knowledge platform: turn raw documents into a queryable RAG, an autonomous reasoning agent, and a self-maintaining Wiki.
Go agentagenticaichatbotdsh-pluginembeddingsevaluationgenerative-aigolangknowledge-basellmmulti-tenantollamaopenaiquestion-answeringragrerankingsemantic-searchvector-searchwiki
fix(searxng): provide hardcoded default SEARXNG_SECRET for zero-config startup
wizardchen6b812a54d270
diff --git a/.env.example b/.env.exampleindex 48a3d5d97..034a9253c 100644--- a/.env.example+++ b/.env.example@@ -204,9 +204,11 @@ SYSTEM_AES_KEY=weknora-system-aes-key-32bytes!!# SSRF_WHITELIST=internal.service,*.corp.example,172.16.0.0/12,2001:db8::1,fd00::/8# ===== SearXNG(可选自建网络搜索)=====-# 启用:先生成强随机 SEARXNG_SECRET,再 `docker compose --profile searxng up -d`。-# openssl rand -hex 32-# 没有 SEARXNG_SECRET 时 docker compose 会主动报错,避免使用公开默认值。+# 启用:`docker compose --profile searxng up -d`。+# SEARXNG_SECRET 不设时使用 docker-compose 中的写死默认值,足够本机/loopback+# 部署使用;如果改 SEARXNG_BIND=0.0.0.0 把实例暴露到 LAN/公网,请务必用+# `openssl rand -hex 32` 生成并显式设置 SEARXNG_SECRET,否则默认值会被任何人+# 用于签名 image-proxy URL。## 后端访问方式(容器化部署):控制台中 Provider 类型选 "SearXNG",# Instance URL 填 http://searxng:8080 ;docker compose 已默认把 `searxng` 主机名diff --git a/docker-compose.dev.yml b/docker-compose.dev.ymlindex c1ecfdb9d..e736a17e6 100644--- a/docker-compose.dev.yml+++ b/docker-compose.dev.yml@@ -63,7 +63,8 @@ services:environment:- SEARXNG_BASE_URL=http://localhost:${SEARXNG_PORT:-8888}/- INSTANCE_NAME=weknora-searxng-dev- - SEARXNG_SECRET=${SEARXNG_SECRET:?SEARXNG_SECRET must be set (e.g. openssl rand -hex 32) before starting the searxng profile}+ # See docker-compose.yml for rationale on the default secret.+ - SEARXNG_SECRET=${SEARXNG_SECRET:-weknora-default-searxng-secret-rotate-before-exposing-publicly}cap_drop:- ALLcap_add:diff --git a/docker-compose.yml b/docker-compose.ymlindex 75980639e..ada7cef84 100644--- a/docker-compose.yml+++ b/docker-compose.yml@@ -272,7 +272,11 @@ services:environment:- SEARXNG_BASE_URL=http://localhost:${SEARXNG_PORT:-8888}/- INSTANCE_NAME=weknora-searxng- - SEARXNG_SECRET=${SEARXNG_SECRET:?SEARXNG_SECRET must be set (e.g. openssl rand -hex 32) before starting the searxng profile}+ # Default value lets `docker compose --profile searxng up` work zero-config.+ # Override via .env (e.g. `openssl rand -hex 32`) before exposing the+ # instance beyond the default 127.0.0.1 bind, since secret_key signs+ # image-proxy URLs and a shared default would be guessable by anyone.+ - SEARXNG_SECRET=${SEARXNG_SECRET:-weknora-default-searxng-secret-rotate-before-exposing-publicly}cap_drop:- ALLcap_add: