EternalAI/hermes-server/.env.example

39 lines
1.5 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# ===== Hermes Server 环境变量配置 =====
# 服务端口
PORT=3002
# Hermes Server 对外访问的基础 URL用于生成二维码绑定链接
# 必须是外部可访问的地址,二维码内容会基于此生成
HERMES_BASE_URL=http://localhost:3002
# ===== EternalAI 地址P0 修复:用于回调拉取文件,不信任请求体) =====
# 配置为 EternalAI 服务器的可访问地址
# hermes-server 会从此地址拉取 SOUL.md 和 config.yaml
ETERNALAI_BASE_URL=http://localhost:3001
# ===== 与 EternalAI 共享的 sync_token 密钥 =====
# 必须与 EternalAI 的 SYNC_SECRET 一致EternalAI 数据库 SystemConfig 表中 key='SYNC_SECRET' 的值)
# 获取方式:在 EternalAI 服务器执行
# psql -d eternalai -c "SELECT value FROM \"SystemConfig\" WHERE key='SYNC_SECRET'"
# 或通过 Prisma Studio 查看
SYNC_SECRET=
# ===== Hermes 管理员认证 =====
# 管理 API查看 profile 列表等)的 Bearer token
# 生产环境务必设置为强随机值(可用 openssl rand -hex 32 生成)
HERMES_ADMIN_TOKEN=dev_only_admin_token_change_me
# ===== 可选EternalAI 地址白名单 =====
# 限制同步请求来源 IP逗号分隔留空则不限制
# 示例ALLOWED_SOURCE_IPS=192.168.1.100,10.0.0.5
ALLOWED_SOURCE_IPS=
# ===== 可选CORS 来源限制 =====
# 限制跨域请求来源(逗号分隔),留空则非生产环境允许所有来源
# 示例ALLOWED_ORIGINS=https://eternalai.example.com,https://admin.eternalai.example.com
ALLOWED_ORIGINS=
# ===== Node 环境 =====
NODE_ENV=development