mirror of
https://gitee.com/qqtt-ah/ecom-dmb.git
synced 2026-11-24 14:29:19 +08:00
fix: 各环境补齐 Agent 与 Server 对齐的 MCP Bearer
This commit is contained in:
@@ -21,6 +21,7 @@ LLM_FALLBACK_BASE_URL=https://api.deepseek.com/v1
|
||||
LLM_FALLBACK_API_KEY=
|
||||
LLM_FALLBACK_MODEL=deepseek-chat
|
||||
CORS_ORIGINS=http://localhost:5173,http://localhost:5666
|
||||
# 须与同环境 Server ecom.agent.mcp.bearer-token / AGENT_MCP_TOKEN 一致;空则 MCP 工具整段跳过
|
||||
MCP_BASE_URL=http://localhost:8080/mcp
|
||||
MCP_BEARER_TOKEN=dev-agent-mcp-token
|
||||
MCP_TOOLS_ENABLED=true
|
||||
|
||||
+1
-1
@@ -12,6 +12,6 @@ LLM_FALLBACK_API_KEY=
|
||||
LLM_FALLBACK_MODEL=
|
||||
CORS_ORIGINS=https://cd.newloop.top
|
||||
MCP_BASE_URL=http://192.168.3.101:8102/mcp
|
||||
MCP_BEARER_TOKEN=
|
||||
MCP_BEARER_TOKEN=pre-agent-mcp-token
|
||||
MCP_TOOLS_ENABLED=true
|
||||
PORT=8202
|
||||
|
||||
@@ -12,6 +12,6 @@ LLM_FALLBACK_API_KEY=
|
||||
LLM_FALLBACK_MODEL=
|
||||
CORS_ORIGINS=https://cd.newloop.top
|
||||
MCP_BASE_URL=http://192.168.3.101:8103/mcp
|
||||
MCP_BEARER_TOKEN=
|
||||
MCP_BEARER_TOKEN=prod-agent-mcp-token
|
||||
MCP_TOOLS_ENABLED=true
|
||||
PORT=8203
|
||||
|
||||
@@ -12,6 +12,6 @@ LLM_FALLBACK_API_KEY=
|
||||
LLM_FALLBACK_MODEL=
|
||||
CORS_ORIGINS=https://cd.newloop.top,http://localhost:5666
|
||||
MCP_BASE_URL=http://192.168.3.101:8101/mcp
|
||||
MCP_BEARER_TOKEN=
|
||||
MCP_BEARER_TOKEN=test-agent-mcp-token
|
||||
MCP_TOOLS_ENABLED=true
|
||||
PORT=8201
|
||||
|
||||
@@ -40,7 +40,7 @@ API 前缀:`/api/agent/...`(会话/聊天/记忆;与前端代理 `/api/age
|
||||
| `MONGO_URI` / `MONGO_DB` | Agent 独立库(sessions / messages / memory) |
|
||||
| `REDIS_URL` | **与同环境 Server 同 DB**,读 LLM 运行时缓存 `agent:llm:rt:*` |
|
||||
| `SERVER_BASE_URL` | Java 根地址,内部拉 `/api/internal/agent/llm-runtime` |
|
||||
| `MCP_BASE_URL` / `MCP_BEARER_TOKEN` | 调 Server `/mcp`,并带 `X-Agent-Company-Id` / `X-Agent-User-Id` |
|
||||
| `MCP_BASE_URL` / `MCP_BEARER_TOKEN` | 调 Server `/mcp`;Bearer 须与 Java `AGENT_MCP_TOKEN` / `ecom.agent.mcp.bearer-token` 一致,空则不加载 MCP 工具 |
|
||||
| `LLM_FALLBACK_*` | 仅本地:公司未配置时的 OpenAI Compatible fallback |
|
||||
| `CHAT_HISTORY_FETCH_LIMIT` | 从 Mongo 最多拉多少条再按 token 裁剪(默认 200) |
|
||||
| `LLM_DEFAULT_CONTEXT_WINDOW` | 无法估计时的默认上下文(默认 128000) |
|
||||
|
||||
@@ -43,6 +43,10 @@ ecom:
|
||||
license-key: ""
|
||||
online-revocation-check: true
|
||||
license-server-url: ""
|
||||
agent:
|
||||
mcp:
|
||||
# 须与 apps/agent/.env.pre 的 MCP_BEARER_TOKEN 一致;可用 AGENT_MCP_TOKEN 覆盖
|
||||
bearer-token: ${AGENT_MCP_TOKEN:pre-agent-mcp-token}
|
||||
|
||||
logging:
|
||||
level:
|
||||
|
||||
@@ -44,6 +44,10 @@ ecom:
|
||||
license-key: ""
|
||||
online-revocation-check: true
|
||||
license-server-url: ""
|
||||
agent:
|
||||
mcp:
|
||||
# 须与 apps/agent/.env.prod 的 MCP_BEARER_TOKEN 一致;可用 AGENT_MCP_TOKEN 覆盖
|
||||
bearer-token: ${AGENT_MCP_TOKEN:prod-agent-mcp-token}
|
||||
|
||||
logging:
|
||||
level:
|
||||
|
||||
@@ -42,6 +42,10 @@ ecom:
|
||||
license-key: ""
|
||||
online-revocation-check: false
|
||||
license-server-url: ""
|
||||
agent:
|
||||
mcp:
|
||||
# 须与 apps/agent/.env.test 的 MCP_BEARER_TOKEN 一致;可用 AGENT_MCP_TOKEN 覆盖
|
||||
bearer-token: ${AGENT_MCP_TOKEN:test-agent-mcp-token}
|
||||
|
||||
logging:
|
||||
level:
|
||||
|
||||
Reference in New Issue
Block a user