v1.4: 多租户开通 + 安全性重构 + 数据脱敏
新增: - provision_server.py HTTP API 服务 (Bottle, 端口 5566) - 状态持久化 (JSON, 每30秒保存, 1小时内可恢复) - 会议室模式 (开发团队 Inbox 多 AI 路由) - supervisor 托管, SIGTERM 优雅退出 - PUBSUB_TOKEN 三级 fallback 修复: - 所有硬编码凭证清除 (CW_EMAIL/CW_PASSWORD 无 fallback) - 双重 WebSocket 重连 - 内存泄漏 (无界 Set 清理) - INBOX_CONFIG 兜底 (skip+log 不崩溃) - PID 文件竞争, Metrics 热路径优化 - 幂等性正确实现 (存真实响应含 HTTP 状态码) 安全: - 完整数据脱敏 (无 URL/邮箱/密码/token 硬编码) - .env.example / chatwoot_auth.example.json / inboxes.example.json
This commit is contained in:
+13
-30
@@ -1,32 +1,15 @@
|
||||
# Chatwoot AI Agent Configuration
|
||||
# ── Chatwoot 连接配置 ──
|
||||
CW_BASE=http://localhost:3000
|
||||
CW_ACCOUNT_ID=1
|
||||
CW_EMAIL=admin@example.com
|
||||
CW_PASSWORD=your-chatwoot-password
|
||||
|
||||
# Chatwoot Instance
|
||||
CHATWOOT_BASE_URL=https://your-chatwoot-domain.com
|
||||
CHATWOOT_WS_URL=wss://your-chatwoot-domain.com/cable
|
||||
# ── WS Agent ──
|
||||
CW_PUBSUB_TOKEN=
|
||||
CW_USER_ID=1
|
||||
|
||||
# API Credentials (create via Chatwoot Profile > Access Token)
|
||||
ACCESS_TOKEN=your_access_token
|
||||
USER_UID=user@email.com
|
||||
USER_TOKEN=your_user_token
|
||||
USER_CLIENT=client_name
|
||||
USER_EXPIRY=expiry_date
|
||||
|
||||
# Account
|
||||
ACCOUNT_ID=1
|
||||
|
||||
# AI Model
|
||||
AI_API_BASE=https://your-llm-api.com
|
||||
AI_MODEL=your-model-name
|
||||
AI_API_KEY=your-api-key
|
||||
|
||||
# AI Agent for Inbox 1 (sourcing-agent)
|
||||
SOURCING_AGENT_ID=sourcing-agent
|
||||
|
||||
# AI Agent for Inbox 7 (halo-blog-agent)
|
||||
HALO_BLOG_AGENT_ID=halo-blog-agent
|
||||
|
||||
# Human timeout (minutes)
|
||||
HUMAN_TIMEOUT_MINUTES=15
|
||||
|
||||
# Logging
|
||||
LOG_LEVEL=INFO
|
||||
# ── Provision Server ──
|
||||
CW_ADMIN_EMAIL=admin@example.com
|
||||
CW_ADMIN_PASSWORD=your-chatwoot-password
|
||||
CW_PLATFORM_TOKEN=your-platform-api-token
|
||||
CHATHUB_API_KEY=change-me-to-a-random-string
|
||||
|
||||
Reference in New Issue
Block a user