# ============================================================================ # LibreDesk 配置模板。bootstrap.sh 会渲染成 config/config.toml(含密钥,不入库)。 # 对齐 v2.8.x / v2.9.x 的 config.sample.toml,只保留本套 POC 需要的项。 # ============================================================================ [app] log_level = "info" env = "dev" check_updates = true encryption_key = "__ENCRYPTION_KEY__" [app.server] address = "0.0.0.0:9000" socket = "" # 本地用 http://localhost:9000 访问,必须关闭 Secure Cookie,否则登录不生效。 # 生产(HTTPS)请改为 false。 disable_secure_cookies = true session_lifetime = "9h" read_timeout = "60s" write_timeout = "60s" max_body_size = 104857600 read_buffer_size = 65536 keepalive_timeout = "10s" [auth] local_login_enabled = true [upload] provider = "fs" [upload.fs] upload_path = "uploads" expiry = "1h" [db] host = "postgres" port = 5432 user = "__DB_USER__" password = "__DB_PASSWORD__" database = "libredesk" ssl_mode = "disable" max_open = 30 max_idle = 30 max_lifetime = "300s" [redis] address = "redis:6379" user = "" password = "" db = 2 [message] outgoing_queue_workers = 10 incoming_queue_workers = 10 message_outgoing_scan_interval = "50ms" incoming_queue_size = 5000 outgoing_queue_size = 5000 [notification] concurrency = 2 queue_size = 2000 [automation] worker_count = 10 time_trigger_lookback_days = 90 [ai_agent] worker_count = 10 queue_size = 1000 # 单次回复最多工具调用步数(1-20) max_steps = 6 # 带给模型的历史消息条数(5-100) max_history_messages = 30 [autoassigner] autoassign_interval = "5m" [webhook] workers = 5 queue_size = 10000 timeout = "15s" [ssrf] # 单租户自托管可以关闭;本套的工具服务跑在宿主机,需要允许内网地址。 enabled = false allowed_cidrs = [] [conversation] unsnooze_interval = "5m" draft_retention_duration = "360h" continuity_scan_interval = "5m" [sla] evaluation_interval = "5m" [rate_limit.widget] enabled = true requests_per_minute = 100 [rate_limit.auth] enabled = true requests_per_minute = 30 [rate_limit.public] enabled = true requests_per_minute = 100 [rate_limit.media] enabled = true requests_per_minute = 300