72 lines
4.9 KiB
Plaintext
72 lines
4.9 KiB
Plaintext
# ═════════════════════════════════════════════════════════════════════════════
|
||
# TDAI 全局镜像本地部署 - 环境变量模板
|
||
#
|
||
# 用法:
|
||
# cp .env.example .env
|
||
# # 编辑 .env,把 REPLACE_ME 换成你自己的值
|
||
# ./start-all.sh
|
||
#
|
||
# 两组独立参数:
|
||
# MEMORY_* → memory + memory-hub 使用(内部记忆/知识服务的 LLM)
|
||
# PROXY_* → proxy 使用(用户请求转发到的上游 LLM)
|
||
# 两组值可以相同,也可以指向完全不同的模型/供应商。
|
||
# ═════════════════════════════════════════════════════════════════════════════
|
||
|
||
# ── 镜像 tag ─────────────────────────────────────────────────────────────────
|
||
# 默认走 Docker Hub 公开镜像(多架构 amd64 + arm64,docker pull 无需登录):
|
||
# https://hub.docker.com/r/agentmemory/memory-core
|
||
# https://hub.docker.com/r/agentmemory/memory-proxy
|
||
# https://hub.docker.com/r/agentmemory/memory-hub
|
||
# 想固定版本时把 :latest 换成具体版本,例如 :1.0.0-beta.1。
|
||
MEMORY_CORE_IMAGE=agentmemory/memory-core:latest
|
||
MEMORY_HUB_IMAGE=agentmemory/memory-hub:latest
|
||
PROXY_IMAGE=agentmemory/memory-proxy:latest
|
||
|
||
# ── 腾讯内网备选(内部同事用) ────────────────────────────────────────────────
|
||
# 内部环境(腾讯办公网/devcloud)可以覆盖成 mirrors.tencent.com 私仓,无需
|
||
# 走公网 Docker Hub。使用前先 `docker login mirrors.tencent.com`。
|
||
# MEMORY_CORE_IMAGE=mirrors.tencent.com/memory-team-control/memory-core:latest
|
||
# MEMORY_HUB_IMAGE=mirrors.tencent.com/memory-team-control/memory-hub:latest
|
||
# PROXY_IMAGE=mirrors.tencent.com/memory-team-control/proxy:latest
|
||
|
||
# ── memory 组:memory + memory-hub 内部调用的 LLM ────────────────────────────
|
||
# 用途:memory 的 embed/summarize;memory-hub 里 knowledge 的 wiki ingest / 总结
|
||
MEMORY_LLM_BASE_URL=REPLACE_ME # 例:https://api.deepseek.com/v1
|
||
MEMORY_LLM_API_KEY=REPLACE_ME # 例:sk-xxxxxxxx
|
||
MEMORY_LLM_MODEL=REPLACE_ME # 例:deepseek-chat
|
||
MEMORY_LLM_PROTOCOL=openai # openai | anthropic
|
||
|
||
# ── proxy 组:proxy 把用户请求转发到的上游 LLM ──────────────────────────────
|
||
# 用途:coding agent / 客户端调 proxy:8096,proxy 再转发到这里
|
||
PROXY_UPSTREAM_URL=REPLACE_ME # 例:https://api.deepseek.com/v1
|
||
PROXY_UPSTREAM_API_KEY=REPLACE_ME # 例:sk-xxxxxxxx(可与 memory 组不同)
|
||
PROXY_UPSTREAM_MODEL=REPLACE_ME # 例:deepseek-chat
|
||
|
||
# ── 端口(默认可直接用;有本地冲突时改这里) ───────────────────────────────
|
||
MEMORY_CORE_PORT=8420
|
||
PANEL_PORT=8125
|
||
KNOWLEDGE_PORT=8424
|
||
PROXY_PORT=8096
|
||
|
||
# ── knowledge 外部可达地址(memory-hub 需要)─────────────────────────────────
|
||
# 让 agent / gateway 能访问到 KS 的 tools 接口。必须含 /v3 前缀。
|
||
# 本地场景默认用 host.docker.internal 让容器内可回环到宿主。
|
||
KNOWLEDGE_PUBLIC_BASE_URL=http://host.docker.internal:8424/v3
|
||
|
||
# ── 数据卷名 ─────────────────────────────────────────────────────────────────
|
||
MEMORY_CORE_VOLUME=tdai-memory-core-data
|
||
PANEL_VOLUME=tdai-panel-data
|
||
|
||
# ── memory-core 内部凭据 ─────────────────────────────────────────────────────
|
||
# Gateway 的 Bearer 层管理凭据。
|
||
# 留空(默认) —— 关闭 Bearer gate(本地零配置体验;proxy 的 auth/sessionInit
|
||
# 仅在此配置下能与 memory-core 直连,见 start-memory-core.sh 顶部注释)
|
||
# 非空 —— 所有请求必须带 `Authorization: Bearer <key>`;proxy 目前
|
||
# 不发这个 header,因此 proxy 的 auth/sessionInit 会失败
|
||
# 生产环境后续需在 proxy 侧修复后再启用非空 key。
|
||
MEMORY_CORE_GATEWAY_API_KEY=
|
||
|
||
# admin 用户名(首次 init-admin 用)。user_key 由脚本首次启动自动生成一把随机 sk-mem-
|
||
# 存到 ./.admin-key —— 后续脚本 / claude-proxy 从此文件读取,不再需要手工填写。
|
||
MEMORY_CORE_ADMIN_USERNAME=admin
|