@lobehub/chat 1.44.3 → 1.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (319) hide show
  1. package/.remarkrc.mdx.js +6 -0
  2. package/CHANGELOG.md +25 -0
  3. package/changelog/v1.json +9 -0
  4. package/docs/changelog/2023-09-09-plugin-system.mdx +5 -0
  5. package/docs/changelog/2023-09-09-plugin-system.zh-CN.mdx +5 -0
  6. package/docs/changelog/2023-11-14-gpt4-vision.mdx +6 -0
  7. package/docs/changelog/2023-11-14-gpt4-vision.zh-CN.mdx +6 -0
  8. package/docs/changelog/2023-11-19-tts-stt.mdx +6 -0
  9. package/docs/changelog/2023-11-19-tts-stt.zh-CN.mdx +7 -0
  10. package/docs/changelog/2023-12-22-dalle-3.mdx +6 -0
  11. package/docs/changelog/2023-12-22-dalle-3.zh-CN.mdx +4 -0
  12. package/docs/changelog/2024-02-08-sso-oauth.mdx +6 -0
  13. package/docs/changelog/2024-02-08-sso-oauth.zh-CN.mdx +6 -0
  14. package/docs/changelog/2024-02-14-ollama.mdx +6 -0
  15. package/docs/changelog/2024-02-14-ollama.zh-CN.mdx +5 -0
  16. package/docs/changelog/2024-06-19-lobe-chat-v1.mdx +6 -0
  17. package/docs/changelog/2024-06-19-lobe-chat-v1.zh-CN.mdx +5 -0
  18. package/docs/changelog/2024-07-19-gpt-4o-mini.mdx +5 -0
  19. package/docs/changelog/2024-07-19-gpt-4o-mini.zh-CN.mdx +4 -0
  20. package/docs/changelog/2024-08-02-lobe-chat-database-docker.mdx +6 -0
  21. package/docs/changelog/2024-08-02-lobe-chat-database-docker.zh-CN.mdx +5 -0
  22. package/docs/changelog/2024-08-21-file-upload-and-knowledge-base.mdx +6 -0
  23. package/docs/changelog/2024-08-21-file-upload-and-knowledge-base.zh-CN.mdx +5 -0
  24. package/docs/changelog/2024-09-13-openai-o1-models.mdx +6 -0
  25. package/docs/changelog/2024-09-13-openai-o1-models.zh-CN.mdx +6 -0
  26. package/docs/changelog/2024-09-20-artifacts.mdx +6 -0
  27. package/docs/changelog/2024-09-20-artifacts.zh-CN.mdx +6 -0
  28. package/docs/changelog/2024-10-27-pin-assistant.mdx +5 -0
  29. package/docs/changelog/2024-10-27-pin-assistant.zh-CN.mdx +4 -0
  30. package/docs/changelog/2024-11-06-share-text-json.mdx +4 -0
  31. package/docs/changelog/2024-11-06-share-text-json.zh-CN.mdx +4 -0
  32. package/docs/changelog/2024-11-25-november-providers.mdx +7 -0
  33. package/docs/changelog/2024-11-25-november-providers.zh-CN.mdx +7 -0
  34. package/docs/changelog/2024-11-27-forkable-chat.mdx +4 -0
  35. package/docs/changelog/2024-11-27-forkable-chat.zh-CN.mdx +5 -0
  36. package/docs/changelog/2025-01-03-user-profile.mdx +5 -0
  37. package/docs/changelog/2025-01-03-user-profile.zh-CN.mdx +4 -1
  38. package/docs/self-hosting/advanced/auth/clerk.mdx +25 -41
  39. package/docs/self-hosting/advanced/auth/clerk.zh-CN.mdx +23 -37
  40. package/docs/self-hosting/advanced/auth/next-auth/auth0.mdx +31 -58
  41. package/docs/self-hosting/advanced/auth/next-auth/auth0.zh-CN.mdx +30 -57
  42. package/docs/self-hosting/advanced/auth/next-auth/authelia.mdx +38 -38
  43. package/docs/self-hosting/advanced/auth/next-auth/authelia.zh-CN.mdx +37 -38
  44. package/docs/self-hosting/advanced/auth/next-auth/authentik.mdx +26 -31
  45. package/docs/self-hosting/advanced/auth/next-auth/authentik.zh-CN.mdx +25 -30
  46. package/docs/self-hosting/advanced/auth/next-auth/casdoor.mdx +74 -75
  47. package/docs/self-hosting/advanced/auth/next-auth/casdoor.zh-CN.mdx +72 -73
  48. package/docs/self-hosting/advanced/auth/next-auth/cloudflare-zero-trust.mdx +24 -25
  49. package/docs/self-hosting/advanced/auth/next-auth/cloudflare-zero-trust.zh-CN.mdx +23 -24
  50. package/docs/self-hosting/advanced/auth/next-auth/github.mdx +46 -73
  51. package/docs/self-hosting/advanced/auth/next-auth/github.zh-CN.mdx +43 -70
  52. package/docs/self-hosting/advanced/auth/next-auth/logto.mdx +28 -37
  53. package/docs/self-hosting/advanced/auth/next-auth/logto.zh-CN.mdx +28 -37
  54. package/docs/self-hosting/advanced/auth/next-auth/microsoft-entra-id.mdx +36 -49
  55. package/docs/self-hosting/advanced/auth/next-auth/microsoft-entra-id.zh-CN.mdx +30 -43
  56. package/docs/self-hosting/advanced/auth/next-auth/wechat.mdx +13 -14
  57. package/docs/self-hosting/advanced/auth/next-auth/wechat.zh-CN.mdx +14 -15
  58. package/docs/self-hosting/advanced/auth/next-auth/zitadel.mdx +35 -69
  59. package/docs/self-hosting/advanced/auth/next-auth/zitadel.zh-CN.mdx +34 -68
  60. package/docs/self-hosting/advanced/auth.mdx +14 -13
  61. package/docs/self-hosting/advanced/auth.zh-CN.mdx +15 -14
  62. package/docs/self-hosting/advanced/feature-flags.zh-CN.mdx +15 -15
  63. package/docs/self-hosting/advanced/knowledge-base.mdx +14 -3
  64. package/docs/self-hosting/advanced/knowledge-base.zh-CN.mdx +12 -3
  65. package/docs/self-hosting/advanced/model-list.zh-CN.mdx +5 -5
  66. package/docs/self-hosting/advanced/s3/cloudflare-r2.mdx +52 -81
  67. package/docs/self-hosting/advanced/s3/cloudflare-r2.zh-CN.mdx +51 -80
  68. package/docs/self-hosting/advanced/s3/tencent-cloud.mdx +20 -34
  69. package/docs/self-hosting/advanced/s3/tencent-cloud.zh-CN.mdx +28 -43
  70. package/docs/self-hosting/advanced/s3.mdx +30 -34
  71. package/docs/self-hosting/advanced/s3.zh-CN.mdx +28 -33
  72. package/docs/self-hosting/advanced/settings-url-share.mdx +6 -6
  73. package/docs/self-hosting/advanced/settings-url-share.zh-CN.mdx +19 -19
  74. package/docs/self-hosting/advanced/upstream-sync.mdx +73 -89
  75. package/docs/self-hosting/advanced/upstream-sync.zh-CN.mdx +71 -87
  76. package/docs/self-hosting/advanced/webrtc.mdx +14 -21
  77. package/docs/self-hosting/advanced/webrtc.zh-CN.mdx +19 -26
  78. package/docs/self-hosting/environment-variables/analytics.zh-CN.mdx +0 -3
  79. package/docs/self-hosting/environment-variables/auth.zh-CN.mdx +1 -1
  80. package/docs/self-hosting/environment-variables/basic.mdx +13 -13
  81. package/docs/self-hosting/environment-variables/basic.zh-CN.mdx +15 -15
  82. package/docs/self-hosting/environment-variables/model-provider.mdx +1 -1
  83. package/docs/self-hosting/environment-variables/model-provider.zh-CN.mdx +1 -1
  84. package/docs/self-hosting/environment-variables/s3.mdx +3 -4
  85. package/docs/self-hosting/environment-variables/s3.zh-CN.mdx +5 -7
  86. package/docs/self-hosting/environment-variables.mdx +8 -4
  87. package/docs/self-hosting/environment-variables.zh-CN.mdx +4 -0
  88. package/docs/self-hosting/examples/azure-openai.mdx +9 -12
  89. package/docs/self-hosting/examples/azure-openai.zh-CN.mdx +8 -11
  90. package/docs/self-hosting/examples/ollama.mdx +8 -7
  91. package/docs/self-hosting/examples/ollama.zh-CN.mdx +8 -7
  92. package/docs/self-hosting/platform/alibaba-cloud.mdx +5 -7
  93. package/docs/self-hosting/platform/alibaba-cloud.zh-CN.mdx +5 -7
  94. package/docs/self-hosting/platform/btpanel.mdx +3 -2
  95. package/docs/self-hosting/platform/btpanel.zh-CN.mdx +3 -3
  96. package/docs/self-hosting/platform/docker-compose.mdx +75 -85
  97. package/docs/self-hosting/platform/docker-compose.zh-CN.mdx +75 -85
  98. package/docs/self-hosting/platform/docker.mdx +87 -92
  99. package/docs/self-hosting/platform/docker.zh-CN.mdx +96 -115
  100. package/docs/self-hosting/platform/netlify.mdx +44 -94
  101. package/docs/self-hosting/platform/netlify.zh-CN.mdx +40 -90
  102. package/docs/self-hosting/platform/railway.mdx +6 -7
  103. package/docs/self-hosting/platform/railway.zh-CN.mdx +6 -7
  104. package/docs/self-hosting/platform/repocloud.mdx +6 -7
  105. package/docs/self-hosting/platform/repocloud.zh-CN.mdx +6 -7
  106. package/docs/self-hosting/platform/sealos.mdx +6 -7
  107. package/docs/self-hosting/platform/sealos.zh-CN.mdx +6 -7
  108. package/docs/self-hosting/platform/vercel.mdx +7 -8
  109. package/docs/self-hosting/platform/vercel.zh-CN.mdx +7 -8
  110. package/docs/self-hosting/platform/zeabur.mdx +29 -32
  111. package/docs/self-hosting/platform/zeabur.zh-CN.mdx +29 -32
  112. package/docs/self-hosting/server-database/docker-compose.mdx +44 -71
  113. package/docs/self-hosting/server-database/docker-compose.zh-CN.mdx +44 -71
  114. package/docs/self-hosting/server-database/docker.mdx +84 -88
  115. package/docs/self-hosting/server-database/docker.zh-CN.mdx +87 -91
  116. package/docs/self-hosting/server-database/dokploy.mdx +18 -1
  117. package/docs/self-hosting/server-database/dokploy.zh-CN.mdx +84 -68
  118. package/docs/self-hosting/server-database/repocloud.mdx +7 -9
  119. package/docs/self-hosting/server-database/repocloud.zh-CN.mdx +9 -11
  120. package/docs/self-hosting/server-database/vercel.mdx +158 -243
  121. package/docs/self-hosting/server-database/vercel.zh-CN.mdx +137 -205
  122. package/docs/self-hosting/server-database/zeabur.mdx +21 -23
  123. package/docs/self-hosting/server-database/zeabur.zh-CN.mdx +20 -22
  124. package/docs/self-hosting/server-database.mdx +34 -36
  125. package/docs/self-hosting/server-database.zh-CN.mdx +34 -37
  126. package/docs/self-hosting/start.mdx +1 -4
  127. package/docs/self-hosting/start.zh-CN.mdx +1 -1
  128. package/docs/usage/agents/agent-organization.mdx +5 -21
  129. package/docs/usage/agents/agent-organization.zh-CN.mdx +5 -21
  130. package/docs/usage/agents/concepts.mdx +4 -4
  131. package/docs/usage/agents/concepts.zh-CN.mdx +4 -4
  132. package/docs/usage/agents/custom-agent.mdx +2 -2
  133. package/docs/usage/agents/custom-agent.zh-CN.mdx +2 -2
  134. package/docs/usage/agents/model.mdx +4 -4
  135. package/docs/usage/agents/model.zh-CN.mdx +6 -6
  136. package/docs/usage/agents/prompt.mdx +5 -6
  137. package/docs/usage/agents/prompt.zh-CN.mdx +5 -6
  138. package/docs/usage/agents/topics.mdx +2 -2
  139. package/docs/usage/agents/topics.zh-CN.mdx +2 -2
  140. package/docs/usage/features/agent-market.mdx +2 -2
  141. package/docs/usage/features/agent-market.zh-CN.mdx +2 -2
  142. package/docs/usage/features/auth.mdx +1 -5
  143. package/docs/usage/features/auth.zh-CN.mdx +1 -5
  144. package/docs/usage/features/database.mdx +1 -5
  145. package/docs/usage/features/database.zh-CN.mdx +1 -5
  146. package/docs/usage/features/local-llm.mdx +2 -6
  147. package/docs/usage/features/local-llm.zh-CN.mdx +2 -6
  148. package/docs/usage/features/mobile.mdx +1 -5
  149. package/docs/usage/features/mobile.zh-CN.mdx +1 -5
  150. package/docs/usage/features/multi-ai-providers.mdx +3 -11
  151. package/docs/usage/features/multi-ai-providers.zh-CN.mdx +3 -11
  152. package/docs/usage/features/plugin-system.mdx +9 -10
  153. package/docs/usage/features/plugin-system.zh-CN.mdx +9 -10
  154. package/docs/usage/features/pwa.mdx +11 -25
  155. package/docs/usage/features/pwa.zh-CN.mdx +11 -25
  156. package/docs/usage/features/text-to-image.mdx +2 -2
  157. package/docs/usage/features/text-to-image.zh-CN.mdx +2 -2
  158. package/docs/usage/features/theme.mdx +1 -6
  159. package/docs/usage/features/theme.zh-CN.mdx +1 -6
  160. package/docs/usage/features/tts.mdx +3 -7
  161. package/docs/usage/features/tts.zh-CN.mdx +3 -7
  162. package/docs/usage/features/vision.mdx +2 -2
  163. package/docs/usage/features/vision.zh-CN.mdx +2 -2
  164. package/docs/usage/foundation/basic.mdx +7 -18
  165. package/docs/usage/foundation/basic.zh-CN.mdx +6 -16
  166. package/docs/usage/foundation/share.mdx +3 -13
  167. package/docs/usage/foundation/share.zh-CN.mdx +3 -13
  168. package/docs/usage/foundation/text2image.mdx +3 -12
  169. package/docs/usage/foundation/text2image.zh-CN.mdx +3 -12
  170. package/docs/usage/foundation/translate.mdx +3 -13
  171. package/docs/usage/foundation/translate.zh-CN.mdx +3 -13
  172. package/docs/usage/foundation/tts-stt.mdx +3 -12
  173. package/docs/usage/foundation/tts-stt.zh-CN.mdx +3 -12
  174. package/docs/usage/foundation/vision.mdx +4 -16
  175. package/docs/usage/foundation/vision.zh-CN.mdx +4 -16
  176. package/docs/usage/plugins/basic-usage.mdx +7 -30
  177. package/docs/usage/plugins/basic-usage.zh-CN.mdx +7 -30
  178. package/docs/usage/plugins/development.mdx +30 -78
  179. package/docs/usage/plugins/development.zh-CN.mdx +31 -79
  180. package/docs/usage/plugins/store.mdx +2 -10
  181. package/docs/usage/plugins/store.zh-CN.mdx +2 -10
  182. package/docs/usage/providers/ai21.mdx +17 -33
  183. package/docs/usage/providers/ai21.zh-CN.mdx +17 -33
  184. package/docs/usage/providers/ai360.mdx +17 -33
  185. package/docs/usage/providers/ai360.zh-CN.mdx +20 -36
  186. package/docs/usage/providers/anthropic.mdx +23 -45
  187. package/docs/usage/providers/anthropic.zh-CN.mdx +22 -44
  188. package/docs/usage/providers/azure.mdx +21 -51
  189. package/docs/usage/providers/azure.zh-CN.mdx +19 -48
  190. package/docs/usage/providers/baichuan.mdx +16 -34
  191. package/docs/usage/providers/baichuan.zh-CN.mdx +15 -33
  192. package/docs/usage/providers/bedrock.mdx +38 -87
  193. package/docs/usage/providers/bedrock.zh-CN.mdx +37 -86
  194. package/docs/usage/providers/cloudflare.mdx +25 -48
  195. package/docs/usage/providers/cloudflare.zh-CN.mdx +24 -45
  196. package/docs/usage/providers/deepseek.mdx +25 -51
  197. package/docs/usage/providers/deepseek.zh-CN.mdx +24 -50
  198. package/docs/usage/providers/fireworksai.mdx +23 -43
  199. package/docs/usage/providers/fireworksai.zh-CN.mdx +21 -41
  200. package/docs/usage/providers/gemini.mdx +20 -46
  201. package/docs/usage/providers/gemini.zh-CN.mdx +20 -46
  202. package/docs/usage/providers/giteeai.mdx +24 -45
  203. package/docs/usage/providers/giteeai.zh-CN.mdx +22 -43
  204. package/docs/usage/providers/github.mdx +19 -45
  205. package/docs/usage/providers/github.zh-CN.mdx +19 -44
  206. package/docs/usage/providers/groq.mdx +12 -29
  207. package/docs/usage/providers/groq.zh-CN.mdx +11 -28
  208. package/docs/usage/providers/hunyuan.mdx +19 -39
  209. package/docs/usage/providers/hunyuan.zh-CN.mdx +18 -38
  210. package/docs/usage/providers/internlm.mdx +21 -38
  211. package/docs/usage/providers/internlm.zh-CN.mdx +19 -36
  212. package/docs/usage/providers/minimax.mdx +24 -50
  213. package/docs/usage/providers/minimax.zh-CN.mdx +22 -48
  214. package/docs/usage/providers/mistral.mdx +21 -39
  215. package/docs/usage/providers/mistral.zh-CN.mdx +20 -38
  216. package/docs/usage/providers/moonshot.mdx +20 -38
  217. package/docs/usage/providers/moonshot.zh-CN.mdx +19 -37
  218. package/docs/usage/providers/novita.mdx +20 -43
  219. package/docs/usage/providers/novita.zh-CN.mdx +19 -42
  220. package/docs/usage/providers/ollama/gemma.mdx +12 -29
  221. package/docs/usage/providers/ollama/gemma.zh-CN.mdx +12 -30
  222. package/docs/usage/providers/ollama/qwen.mdx +17 -32
  223. package/docs/usage/providers/ollama/qwen.zh-CN.mdx +12 -27
  224. package/docs/usage/providers/ollama.mdx +67 -99
  225. package/docs/usage/providers/ollama.zh-CN.mdx +67 -99
  226. package/docs/usage/providers/openai.mdx +42 -56
  227. package/docs/usage/providers/openai.zh-CN.mdx +39 -52
  228. package/docs/usage/providers/openrouter.mdx +48 -84
  229. package/docs/usage/providers/openrouter.zh-CN.mdx +31 -67
  230. package/docs/usage/providers/perplexity.mdx +16 -34
  231. package/docs/usage/providers/perplexity.zh-CN.mdx +16 -34
  232. package/docs/usage/providers/qwen.mdx +26 -52
  233. package/docs/usage/providers/qwen.zh-CN.mdx +25 -51
  234. package/docs/usage/providers/sensenova.mdx +24 -45
  235. package/docs/usage/providers/sensenova.zh-CN.mdx +22 -43
  236. package/docs/usage/providers/siliconcloud.mdx +17 -33
  237. package/docs/usage/providers/siliconcloud.zh-CN.mdx +17 -33
  238. package/docs/usage/providers/spark.mdx +20 -40
  239. package/docs/usage/providers/spark.zh-CN.mdx +19 -39
  240. package/docs/usage/providers/stepfun.mdx +17 -35
  241. package/docs/usage/providers/stepfun.zh-CN.mdx +17 -35
  242. package/docs/usage/providers/taichu.mdx +16 -34
  243. package/docs/usage/providers/taichu.zh-CN.mdx +15 -33
  244. package/docs/usage/providers/togetherai.mdx +18 -40
  245. package/docs/usage/providers/togetherai.zh-CN.mdx +18 -40
  246. package/docs/usage/providers/upstage.mdx +18 -34
  247. package/docs/usage/providers/upstage.zh-CN.mdx +17 -33
  248. package/docs/usage/providers/wenxin.mdx +22 -42
  249. package/docs/usage/providers/wenxin.zh-CN.mdx +20 -40
  250. package/docs/usage/providers/xai.mdx +21 -38
  251. package/docs/usage/providers/xai.zh-CN.mdx +20 -37
  252. package/docs/usage/providers/zeroone.mdx +22 -48
  253. package/docs/usage/providers/zeroone.zh-CN.mdx +22 -48
  254. package/docs/usage/providers/zhipu.mdx +17 -35
  255. package/docs/usage/providers/zhipu.zh-CN.mdx +18 -34
  256. package/docs/usage/providers.mdx +1 -6
  257. package/docs/usage/providers.zh-CN.mdx +1 -6
  258. package/docs/usage/start.mdx +4 -18
  259. package/docs/usage/start.zh-CN.mdx +2 -19
  260. package/docs/usage/tools-calling/anthropic.mdx +18 -51
  261. package/docs/usage/tools-calling/anthropic.zh-CN.mdx +22 -55
  262. package/docs/usage/tools-calling/google.mdx +16 -23
  263. package/docs/usage/tools-calling/google.zh-CN.mdx +17 -24
  264. package/docs/usage/tools-calling/groq.mdx +9 -0
  265. package/docs/usage/tools-calling/groq.zh-CN.mdx +44 -70
  266. package/docs/usage/tools-calling/moonshot.mdx +9 -0
  267. package/docs/usage/tools-calling/openai.mdx +19 -44
  268. package/docs/usage/tools-calling/openai.zh-CN.mdx +20 -45
  269. package/docs/usage/tools-calling.mdx +9 -0
  270. package/docs/usage/tools-calling.zh-CN.mdx +60 -68
  271. package/package.json +42 -41
  272. package/scripts/mdxWorkflow/index.ts +7 -0
  273. package/src/app/(main)/(mobile)/me/(home)/features/Header.tsx +2 -1
  274. package/src/app/(main)/(mobile)/me/data/features/Header.tsx +1 -1
  275. package/src/app/(main)/(mobile)/me/profile/features/Header.tsx +1 -1
  276. package/src/app/(main)/(mobile)/me/settings/features/Header.tsx +1 -1
  277. package/src/app/(main)/@nav/_layout/Mobile.tsx +2 -1
  278. package/src/app/(main)/chat/(workspace)/@topic/features/SystemRole/SystemRoleContent.tsx +2 -1
  279. package/src/app/(main)/chat/(workspace)/@topic/features/TopicListContent/ByTimeMode/GroupItem.tsx +2 -2
  280. package/src/app/(main)/chat/(workspace)/_layout/Desktop/ChatHeader/Main.tsx +2 -1
  281. package/src/app/(main)/chat/(workspace)/_layout/Desktop/ChatHeader/index.tsx +1 -1
  282. package/src/app/(main)/chat/(workspace)/_layout/Mobile/ChatHeader/ChatHeaderTitle.tsx +2 -1
  283. package/src/app/(main)/chat/(workspace)/_layout/Mobile/ChatHeader/index.tsx +1 -1
  284. package/src/app/(main)/chat/@session/_layout/Mobile/SessionHeader.tsx +2 -1
  285. package/src/app/(main)/chat/settings/_layout/Desktop/Header.tsx +1 -1
  286. package/src/app/(main)/chat/settings/_layout/Mobile/Header.tsx +1 -1
  287. package/src/app/(main)/discover/(detail)/provider/[slug]/features/InfoSidebar/SuggestionItem.tsx +8 -6
  288. package/src/app/(main)/discover/(list)/_layout/Desktop/Nav.tsx +1 -1
  289. package/src/app/(main)/discover/(list)/_layout/Mobile/Header.tsx +2 -1
  290. package/src/app/(main)/discover/_layout/Desktop/Header.tsx +1 -1
  291. package/src/app/(main)/discover/components/VirtuosoGridList/index.tsx +9 -5
  292. package/src/app/(main)/discover/search/_layout/Mobile/Header.tsx +1 -1
  293. package/src/app/(main)/files/(content)/@menu/features/KnowledgeBase/EmptyStatus.tsx +21 -13
  294. package/src/app/(main)/repos/[id]/evals/evaluation/EvaluationList/index.tsx +1 -1
  295. package/src/app/(main)/settings/sync/features/DeviceInfo/SystemIcon.tsx +2 -0
  296. package/src/components/Branding/ProductLogo/Custom.tsx +19 -20
  297. package/src/components/BrowserIcon/index.tsx +19 -30
  298. package/src/components/BubblesLoading/index.tsx +31 -23
  299. package/src/components/FunctionModal/createModalHooks.ts +6 -3
  300. package/src/components/StopLoading.tsx +10 -7
  301. package/src/features/ChatInput/Desktop/InputArea/index.tsx +2 -2
  302. package/src/features/InitClientDB/EnableModal.tsx +2 -2
  303. package/src/features/InitClientDB/{PGliteSVG.tsx → PGliteIcon.tsx} +17 -11
  304. package/src/features/ShareModal/ShareImage/index.tsx +32 -22
  305. package/src/features/ShareModal/ShareJSON/Preview.tsx +2 -2
  306. package/src/features/ShareModal/ShareJSON/index.tsx +49 -37
  307. package/src/features/ShareModal/ShareText/Preview.tsx +4 -1
  308. package/src/features/ShareModal/ShareText/index.tsx +49 -38
  309. package/src/features/ShareModal/index.tsx +1 -1
  310. package/src/features/ShareModal/style.ts +30 -0
  311. package/src/utils/colorUtils.ts +1 -1
  312. package/src/components/BrowserIcon/components/Brave.tsx +0 -56
  313. package/src/components/BrowserIcon/components/Chrome.tsx +0 -14
  314. package/src/components/BrowserIcon/components/Chromium.tsx +0 -14
  315. package/src/components/BrowserIcon/components/Edge.tsx +0 -36
  316. package/src/components/BrowserIcon/components/Firefox.tsx +0 -38
  317. package/src/components/BrowserIcon/components/Opera.tsx +0 -19
  318. package/src/components/BrowserIcon/components/Safari.tsx +0 -23
  319. package/src/components/BrowserIcon/components/Samsung.tsx +0 -21
@@ -15,10 +15,9 @@ tags:
15
15
  <div style={{display:"flex", gap: 4}}>
16
16
  [![][docker-release-shield]][docker-release-link]
17
17
 
18
- [![][docker-size-shield]][docker-size-link]
19
-
20
- [![][docker-pulls-shield]][docker-pulls-link]
18
+ [![][docker-size-shield]][docker-size-link]
21
19
 
20
+ [![][docker-pulls-shield]][docker-pulls-link]
22
21
  </div>
23
22
 
24
23
  <Callout type="info">
@@ -32,8 +31,7 @@ tags:
32
31
  <Callout type="warning">
33
32
  Due to the inability to expose `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY` using Docker environment variables, you cannot use Clerk as an authentication service when deploying LobeChat using Docker / Docker Compose.
34
33
 
35
- If you do need Clerk as an authentication service, you might consider deploying using Vercel or building your own image.
36
-
34
+ If you do need Clerk as an authentication service, you might consider deploying using Vercel or building your own image.
37
35
  </Callout>
38
36
 
39
37
  ## Deploying on a Linux Server
@@ -41,89 +39,87 @@ If you do need Clerk as an authentication service, you might consider deploying
41
39
  Here is the process for deploying the LobeChat server database version on a Linux server:
42
40
 
43
41
  <Steps>
44
-
45
- ### Create a Postgres Database Instance
46
-
47
- Please create a Postgres database instance with the PGVector plugin according to your needs, for example:
48
-
49
- ```sh
50
- docker network create pg
51
-
52
- docker run --name my-postgres --network pg -e POSTGRES_PASSWORD=mysecretpassword -p 5432:5432 -d pgvector/pgvector:pg16
53
- ```
54
-
55
- The above command will create a PG instance named `my-postgres` on the network `pg`, where `pgvector/pgvector:pg16` is a Postgres 16 image with the pgvector plugin installed by default.
56
-
57
- <Callout type="info">
58
- The pgvector plugin provides vector search capabilities for Postgres, which is an important
59
- component for LobeChat to implement RAG.
60
- </Callout>
61
-
62
- <Callout type="warning">
63
- The above command does not specify a persistent storage location for the pg instance, so it is
64
- only for testing/demonstration purposes. Please configure persistent storage for production
65
- environments.
66
- </Callout>
67
-
68
- ### Create a file named `lobe-chat.env` to store environment variables:
69
-
70
- ```shell
71
- # Website domain
72
- APP_URL=https://your-prod-domain.com
73
-
74
- # DB required environment variables
75
- KEY_VAULTS_SECRET=jgwsK28dspyVQoIf8/M3IIHl1h6LYYceSYNXeLpy6uk=
76
- # Postgres database connection string
77
- # Format: postgres://username:password@host:port/dbname; if your pg instance is a Docker container, use the container name
78
- DATABASE_URL=postgres://postgres:mysecretpassword@my-postgres:5432/postgres
79
-
80
- # NEXT_AUTH related, can use auth0, Azure AD, GitHub, Authentik, zitadel, etc. If you have other access requirements, feel free to submit a PR
81
- NEXT_AUTH_SECRET=3904039cd41ea1bdf6c93db0db96e250
82
- NEXT_AUTH_SSO_PROVIDERS=auth0
83
- NEXTAUTH_URL=https://your-prod-domain.com/api/auth
84
- AUTH_AUTH0_ID=xxxxxx
85
- AUTH_AUTH0_SECRET=cSX_xxxxx
86
- AUTH_AUTH0_ISSUER=https://lobe-chat-demo.us.auth0.com
87
-
88
- # S3 related
89
- S3_ACCESS_KEY_ID=xxxxxxxxxx
90
- S3_SECRET_ACCESS_KEY=xxxxxxxxxx
91
- S3_ENDPOINT=https://xxxxxxxxxx.r2.cloudflarestorage.com
92
- S3_BUCKET=lobechat
93
- S3_PUBLIC_DOMAIN=https://s3-for-lobechat.your-domain.com
94
-
95
- # Other environment variables, as needed. You can refer to the environment variables configuration for the client version, making sure not to have ACCESS_CODE.
96
- # OPENAI_API_KEY=sk-xxxx
97
- # OPENAI_PROXY_URL=https://api.openai.com/v1
98
- # OPENAI_MODEL_LIST=...
99
- ```
100
-
101
- ### Start the lobe-chat-database Docker image
102
-
103
- ```sh
104
- docker run -it -d -p 3210:3210 --network pg --env-file lobe-chat.env --name lobe-chat-database lobehub/lobe-chat-database
105
- ```
106
-
107
- You can use the following command to check the logs:
108
-
109
- ```sh
110
- docker logs -f lobe-chat-database
111
- ```
112
-
113
- If you see the following logs in the container, it means it has started successfully:
114
-
115
- ```log
116
- [Database] Start to migration...
117
- ✅ database migration pass.
118
- -------------------------------------
119
- Next.js 14.x.x
120
- - Local: http://localhost:3210
121
- - Network: http://0.0.0.0:3210
122
-
123
- Starting...
124
- ✓ Ready in 95ms
125
- ```
126
-
42
+ ### Create a Postgres Database Instance
43
+
44
+ Please create a Postgres database instance with the PGVector plugin according to your needs, for example:
45
+
46
+ ```sh
47
+ docker network create pg
48
+
49
+ docker run --name my-postgres --network pg -e POSTGRES_PASSWORD=mysecretpassword -p 5432:5432 -d pgvector/pgvector:pg16
50
+ ```
51
+
52
+ The above command will create a PG instance named `my-postgres` on the network `pg`, where `pgvector/pgvector:pg16` is a Postgres 16 image with the pgvector plugin installed by default.
53
+
54
+ <Callout type="info">
55
+ The pgvector plugin provides vector search capabilities for Postgres, which is an important
56
+ component for LobeChat to implement RAG.
57
+ </Callout>
58
+
59
+ <Callout type="warning">
60
+ The above command does not specify a persistent storage location for the pg instance, so it is
61
+ only for testing/demonstration purposes. Please configure persistent storage for production
62
+ environments.
63
+ </Callout>
64
+
65
+ ### Create a file named `lobe-chat.env` to store environment variables:
66
+
67
+ ```shell
68
+ # Website domain
69
+ APP_URL=https://your-prod-domain.com
70
+
71
+ # DB required environment variables
72
+ KEY_VAULTS_SECRET=jgwsK28dspyVQoIf8/M3IIHl1h6LYYceSYNXeLpy6uk=
73
+ # Postgres database connection string
74
+ # Format: postgres://username:password@host:port/dbname; if your pg instance is a Docker container, use the container name
75
+ DATABASE_URL=postgres://postgres:mysecretpassword@my-postgres:5432/postgres
76
+
77
+ # NEXT_AUTH related, can use auth0, Azure AD, GitHub, Authentik, zitadel, etc. If you have other access requirements, feel free to submit a PR
78
+ NEXT_AUTH_SECRET=3904039cd41ea1bdf6c93db0db96e250
79
+ NEXT_AUTH_SSO_PROVIDERS=auth0
80
+ NEXTAUTH_URL=https://your-prod-domain.com/api/auth
81
+ AUTH_AUTH0_ID=xxxxxx
82
+ AUTH_AUTH0_SECRET=cSX_xxxxx
83
+ AUTH_AUTH0_ISSUER=https://lobe-chat-demo.us.auth0.com
84
+
85
+ # S3 related
86
+ S3_ACCESS_KEY_ID=xxxxxxxxxx
87
+ S3_SECRET_ACCESS_KEY=xxxxxxxxxx
88
+ S3_ENDPOINT=https://xxxxxxxxxx.r2.cloudflarestorage.com
89
+ S3_BUCKET=lobechat
90
+ S3_PUBLIC_DOMAIN=https://s3-for-lobechat.your-domain.com
91
+
92
+ # Other environment variables, as needed. You can refer to the environment variables configuration for the client version, making sure not to have ACCESS_CODE.
93
+ # OPENAI_API_KEY=sk-xxxx
94
+ # OPENAI_PROXY_URL=https://api.openai.com/v1
95
+ # OPENAI_MODEL_LIST=...
96
+ ```
97
+
98
+ ### Start the lobe-chat-database Docker image
99
+
100
+ ```sh
101
+ docker run -it -d -p 3210:3210 --network pg --env-file lobe-chat.env --name lobe-chat-database lobehub/lobe-chat-database
102
+ ```
103
+
104
+ You can use the following command to check the logs:
105
+
106
+ ```sh
107
+ docker logs -f lobe-chat-database
108
+ ```
109
+
110
+ If you see the following logs in the container, it means it has started successfully:
111
+
112
+ ```log
113
+ [Database] Start to migration...
114
+ database migration pass.
115
+ -------------------------------------
116
+ ▲ Next.js 14.x.x
117
+ - Local: http://localhost:3210
118
+ - Network: http://0.0.0.0:3210
119
+
120
+ ✓ Starting...
121
+ Ready in 95ms
122
+ ```
127
123
  </Steps>
128
124
 
129
125
  <Callout type="tip">
@@ -13,10 +13,9 @@ tags:
13
13
  <div style={{display:"flex", gap: 4}}>
14
14
  [![][docker-release-shield]][docker-release-link]
15
15
 
16
- [![][docker-size-shield]][docker-size-link]
17
-
18
- [![][docker-pulls-shield]][docker-pulls-link]
16
+ [![][docker-size-shield]][docker-size-link]
19
17
 
18
+ [![][docker-pulls-shield]][docker-pulls-link]
20
19
  </div>
21
20
 
22
21
  <Callout type="info">
@@ -31,8 +30,7 @@ tags:
31
30
  由于无法使用 Docker 环境变量暴露 `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY`,使用 Docker / Docker Compose
32
31
  部署 LobeChat 时,你不能使用 Clerk 作为登录鉴权服务。
33
32
 
34
- 如果你确实需要 Clerk 作为登录鉴权服务,你可以考虑使用 Vercel 部署或者自行构建镜像。
35
-
33
+ 如果你确实需要 Clerk 作为登录鉴权服务,你可以考虑使用 Vercel 部署或者自行构建镜像。
36
34
  </Callout>
37
35
 
38
36
  ## 在 Linux 服务器上部署
@@ -40,92 +38,90 @@ tags:
40
38
  以下是在 Linux 服务器上部署 LobeChat DB 版的流程:
41
39
 
42
40
  <Steps>
43
-
44
- ### 创建 Postgres 数据库实例
45
-
46
- 请按照你自己的诉求创建一个带有 PGVector 插件的 Postgres 数据库实例,例如:
47
-
48
- ```sh
49
- docker network create pg
50
-
51
- docker run --name my-postgres --network pg -e POSTGRES_PASSWORD=mysecretpassword -p 5432:5432 -d pgvector/pgvector:pg16
52
- ```
53
-
54
- 上述指令会创建一个名为 `my-postgres`,并且网络为 `pg` 的 PG 实例,其中 `pgvector/pgvector:pg16` 是一个 Postgres 16 的镜像,且默认安装了 pgvector 插件。
55
-
56
- <Callout type="info">
57
- pgvector 插件为 Postgres 提供了向量搜索的能力,是 LobeChat 实现 RAG 的重要构件之一。
58
- </Callout>
59
-
60
- <Callout type="warning">
61
- 以上指令得到的 pg
62
- 实例并没有指定持久化存储位置,因此仅用于测试/演示,生产环境请自行配置持久化存储。
63
- </Callout>
64
-
65
- ### 创建名为 `lobe-chat.env` 文件用于存放环境变量:
66
-
67
- ```shell
68
- # 网站域名
69
- APP_URL=https://your-prod-domain.com
70
-
71
- # DB 必须的环境变量
72
- # 用于加密敏感信息的密钥,可以使用 openssl rand -base64 32 生成
73
- KEY_VAULTS_SECRET='jgwsK28dspyVQoIf8/M3IIHl1h6LYYceSYNXeLpy6uk='
74
- # Postgres 数据库连接字符串
75
- # 格式:postgres://username:password@host:port/dbname,如果你的 pg 实例为 Docker 容器,请使用容器名
76
- DATABASE_URL=postgres://postgres:mysecretpassword@my-postgres:5432/postgres
77
-
78
- # NEXT_AUTH 相关,可以使用 auth0、Azure AD、GitHub、Authentik、zitadel 等,如有其他接入诉求欢迎提 PR
79
- NEXT_AUTH_SECRET=3904039cd41ea1bdf6c93db0db96e250
80
- NEXT_AUTH_SSO_PROVIDERS=auth0
81
- NEXTAUTH_URL=https://your-prod-domain.com/api/auth
82
- AUTH_AUTH0_ID=xxxxxx
83
- AUTH_AUTH0_SECRET=cSX_xxxxx
84
- AUTH_AUTH0_ISSUER=https://lobe-chat-demo.us.auth0.com
85
-
86
- # S3 相关
87
- S3_ACCESS_KEY_ID=xxxxxxxxxx
88
- S3_SECRET_ACCESS_KEY=xxxxxxxxxx
89
- # 用于 S3 API 访问的域名
90
- S3_ENDPOINT=https://xxxxxxxxxx.r2.cloudflarestorage.com
91
- S3_BUCKET=lobechat
92
- # 用于外网访问 S3 的公共域名,需配置 CORS
93
- S3_PUBLIC_DOMAIN=https://s3-for-lobechat.your-domain.com
94
- # S3_REGION=ap-chengdu # 如果需要指定地域
95
-
96
- # 其他环境变量,视需求而定
97
- # OPENAI_API_KEY=sk-xxxx
98
- # OPENAI_PROXY_URL=https://api.openai.com/v1
99
- # OPENAI_MODEL_LIST=...
100
- # ...
101
- ```
102
-
103
- ### 启动 lobe-chat-database docker 镜像
104
-
105
- ```sh
106
- docker run -it -d -p 3210:3210 --network pg --env-file lobe-chat.env --name lobe-chat-database lobehub/lobe-chat-database
107
- ```
108
-
109
- 你可以使用下述指令检查日志:
110
-
111
- ```sh
112
- docker logs -f lobe-chat-database
113
- ```
114
-
115
- 如果你在容器中看到了以下日志,则说明已经启动成功:
116
-
117
- ```log
118
- [Database] Start to migration...
119
- ✅ database migration pass.
120
- -------------------------------------
121
- Next.js 14.x.x
122
- - Local: http://localhost:3210
123
- - Network: http://0.0.0.0:3210
124
-
125
- Starting...
126
- ✓ Ready in 95ms
127
- ```
128
-
41
+ ### 创建 Postgres 数据库实例
42
+
43
+ 请按照你自己的诉求创建一个带有 PGVector 插件的 Postgres 数据库实例,例如:
44
+
45
+ ```sh
46
+ docker network create pg
47
+
48
+ docker run --name my-postgres --network pg -e POSTGRES_PASSWORD=mysecretpassword -p 5432:5432 -d pgvector/pgvector:pg16
49
+ ```
50
+
51
+ 上述指令会创建一个名为 `my-postgres`,并且网络为 `pg` 的 PG 实例,其中 `pgvector/pgvector:pg16` 是一个 Postgres 16 的镜像,且默认安装了 pgvector 插件。
52
+
53
+ <Callout type="info">
54
+ pgvector 插件为 Postgres 提供了向量搜索的能力,是 LobeChat 实现 RAG 的重要构件之一。
55
+ </Callout>
56
+
57
+ <Callout type="warning">
58
+ 以上指令得到的 pg
59
+ 实例并没有指定持久化存储位置,因此仅用于测试 / 演示,生产环境请自行配置持久化存储。
60
+ </Callout>
61
+
62
+ ### 创建名为 `lobe-chat.env` 文件用于存放环境变量:
63
+
64
+ ```shell
65
+ # 网站域名
66
+ APP_URL=https://your-prod-domain.com
67
+
68
+ # DB 必须的环境变量
69
+ # 用于加密敏感信息的密钥,可以使用 openssl rand -base64 32 生成
70
+ KEY_VAULTS_SECRET='jgwsK28dspyVQoIf8/M3IIHl1h6LYYceSYNXeLpy6uk='
71
+ # Postgres 数据库连接字符串
72
+ # 格式:postgres://username:password@host:port/dbname,如果你的 pg 实例为 Docker 容器,请使用容器名
73
+ DATABASE_URL=postgres://postgres:mysecretpassword@my-postgres:5432/postgres
74
+
75
+ # NEXT_AUTH 相关,可以使用 auth0、Azure AD、GitHub、Authentik、zitadel 等,如有其他接入诉求欢迎提 PR
76
+ NEXT_AUTH_SECRET=3904039cd41ea1bdf6c93db0db96e250
77
+ NEXT_AUTH_SSO_PROVIDERS=auth0
78
+ NEXTAUTH_URL=https://your-prod-domain.com/api/auth
79
+ AUTH_AUTH0_ID=xxxxxx
80
+ AUTH_AUTH0_SECRET=cSX_xxxxx
81
+ AUTH_AUTH0_ISSUER=https://lobe-chat-demo.us.auth0.com
82
+
83
+ # S3 相关
84
+ S3_ACCESS_KEY_ID=xxxxxxxxxx
85
+ S3_SECRET_ACCESS_KEY=xxxxxxxxxx
86
+ # 用于 S3 API 访问的域名
87
+ S3_ENDPOINT=https://xxxxxxxxxx.r2.cloudflarestorage.com
88
+ S3_BUCKET=lobechat
89
+ # 用于外网访问 S3 的公共域名,需配置 CORS
90
+ S3_PUBLIC_DOMAIN=https://s3-for-lobechat.your-domain.com
91
+ # S3_REGION=ap-chengdu # 如果需要指定地域
92
+
93
+ # 其他环境变量,视需求而定
94
+ # OPENAI_API_KEY=sk-xxxx
95
+ # OPENAI_PROXY_URL=https://api.openai.com/v1
96
+ # OPENAI_MODEL_LIST=...
97
+ # ...
98
+ ```
99
+
100
+ ### 启动 lobe-chat-database docker 镜像
101
+
102
+ ```sh
103
+ docker run -it -d -p 3210:3210 --network pg --env-file lobe-chat.env --name lobe-chat-database lobehub/lobe-chat-database
104
+ ```
105
+
106
+ 你可以使用下述指令检查日志:
107
+
108
+ ```sh
109
+ docker logs -f lobe-chat-database
110
+ ```
111
+
112
+ 如果你在容器中看到了以下日志,则说明已经启动成功:
113
+
114
+ ```log
115
+ [Database] Start to migration...
116
+ database migration pass.
117
+ -------------------------------------
118
+ ▲ Next.js 14.x.x
119
+ - Local: http://localhost:3210
120
+ - Network: http://0.0.0.0:3210
121
+
122
+ ✓ Starting...
123
+ Ready in 95ms
124
+ ```
129
125
  </Steps>
130
126
 
131
127
  <Callout type="tip">
@@ -11,14 +11,19 @@ tags:
11
11
  ---
12
12
 
13
13
  # Deploying Server Database Version on Dokploy.
14
+
14
15
  This article will detail how to deploy the server database version of LobeChat.
16
+
15
17
  ## 1. Preparation Work
18
+
16
19
  ### Deploy Dokploy and configure related settings.
20
+
17
21
  ```shell
18
22
  curl -sSL https://dokploy.com/install.sh | sh
19
23
  ```
24
+
20
25
  1. Connect your GitHub to Dokploy in the Settings / Git section according to the prompt.
21
-
26
+
22
27
  ![](https://github.com/user-attachments/assets/c75eb19e-e0f5-4135-91e4-55be8be8a996)
23
28
 
24
29
  2. Enter the Projects interface to create a Project.
@@ -26,7 +31,9 @@ curl -sSL https://dokploy.com/install.sh | sh
26
31
  ![](https://github.com/user-attachments/assets/4e04928d-0171-48d1-afff-e22fc2faaf4e)
27
32
 
28
33
  ### Configure S3 Storage Service
34
+
29
35
  In the server-side database, we need to configure the S3 storage service to store files. For detailed configuration instructions, please refer to the section [Configure S3 Storage Service](https://lobehub.com/docs/self-hosting/server-database/vercel#3-configure-s-3-storage-service) in the Vercel deployment guide。After the configuration is complete, you will obtain the following environment variables:
36
+
30
37
  ```shell
31
38
  S3_ACCESS_KEY_ID=
32
39
  S3_SECRET_ACCESS_KEY=
@@ -35,28 +42,36 @@ S3_BUCKET=
35
42
  S3_PUBLIC_DOMAIN=
36
43
  S3_ENABLE_PATH_STYLE=
37
44
  ```
45
+
38
46
  ### Configure the Clerk authentication service.
47
+
39
48
  Obtain the three environment variables: `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY`, `CLERK_SECRET_KEY`, and `CLERK_WEBHOOK_SECRET`. For detailed configuration steps for Clerk, please refer to the section [Configure Authentication Service](https://lobehub.com/docs/self-hosting/server-database/vercel#2-configure-authentication-service) in the Vercel deployment guide.
49
+
40
50
  ```shell
41
51
  NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_live_xxxxxxxxxxx
42
52
  CLERK_SECRET_KEY=sk_live_xxxxxxxxxxxxxxxxxxxxxx
43
53
  CLERK_WEBHOOK_SECRET=whsec_xxxxxxxxxxxxxxxxxxxxxx
44
54
  ```
55
+
45
56
  ## 2. Deploying the database on Dokploy
57
+
46
58
  Enter the previously created Project, click on Create Service, and select Database. In the Database interface, choose PostgreSQL, then set the database name, user, and password. In the Docker image field, enter `pgvector/pgvector:pg17`, and finally click Create to create the database.
47
59
 
48
60
  ![](https://github.com/user-attachments/assets/97899819-278f-42fd-804a-144d521d4b4f)
49
61
 
50
62
  Enter the created database and set an unused port in External Credentials to allow external access; otherwise, LobeChat will not be able to connect to the database.
51
63
  You can view the Postgres database connection URL in External Host, as shown below:
64
+
52
65
  ```shell
53
66
  postgresql://postgres:wAbLxfXSwkxxxxxx@45.577.281.48:5432/postgres
54
67
  ```
68
+
55
69
  Finally, click Deploy to deploy the database.
56
70
 
57
71
  ![](https://github.com/user-attachments/assets/b4e89dd4-877b-43fe-aa42-4680de17ba8e)
58
72
 
59
73
  ## Deploy LobeChat on Dokploy.
74
+
60
75
  Click "Create Service", select "Application", and create the LobeChat application.
61
76
 
62
77
  ![](https://github.com/user-attachments/assets/4cbbbcce-36be-48ff-bb0b-31607a0bba5c)
@@ -106,6 +121,7 @@ OPENAI_API_KEY=
106
121
  OPENAI_MODEL_LIST=
107
122
  OPENAI_PROXY_URL=
108
123
  ```
124
+
109
125
  After adding the environment variables and saving, click Deploy to initiate the deployment. You can check the deployment progress and log information under Deployments.
110
126
 
111
127
  ![](https://github.com/user-attachments/assets/411e2002-61f0-4010-9841-18e88ca895ec)
@@ -115,6 +131,7 @@ After a successful deployment, bind your own domain to your LobeChat application
115
131
  ![](https://github.com/user-attachments/assets/dd6bc4a4-3c20-4162-87fd-5cac57e5d7e7)
116
132
 
117
133
  ## Check if LobeChat is working properly.
134
+
118
135
  Go to your LobeChat website, and if you click on the login button in the upper left corner and the login pop-up appears normally, it means you have configured it successfully. Enjoy it to the fullest!
119
136
 
120
137
  ![](https://github.com/user-attachments/assets/798ddb18-50c7-462a-a083-0c6841351d26)
@@ -10,67 +10,82 @@ tags:
10
10
  - 身份验证服务
11
11
  - 环境变量配置
12
12
  ---
13
-
14
- # 在 Dokploy 上部署服务端数据库版
15
- 本文将详细介绍如何在 Dokploy 中部署服务端数据库版 LobeChat。
16
- ## 一、准备工作
17
- ### 部署 Dokploy 并进行相关设置
18
- ```shell
19
- curl -sSL https://dokploy.com/install.sh | sh
20
- ```
21
- 1. 在 Dokploy 的 Settings / Git 处根据提示将 Github 绑定到 Dokploy
22
-
23
- ![](https://github.com/user-attachments/assets/c75eb19e-e0f5-4135-91e4-55be8be8a996)
24
-
25
- 2. 进入 Projects 界面创建一个 Project
26
-
27
- ![](https://github.com/user-attachments/assets/4e04928d-0171-48d1-afff-e22fc2faaf4e)
28
-
29
- ### 配置 S3 存储服务
30
- 在服务端数据库中我们需要配置 S3 存储服务来存储文件,详细配置教程请参考 使用 Vercel 部署中 [配置S3储存服务](https://lobehub.com/zh/docs/self-hosting/server-database/vercel#%E4%B8%89%E3%80%81-%E9%85%8D%E7%BD%AE-s-3-%E5%AD%98%E5%82%A8%E6%9C%8D%E5%8A%A1)。配置完成后你将获得以下环境变量:
31
- ```shell
13
+
14
+ # 在 Dokploy 上部署服务端数据库版
15
+
16
+ 本文将详细介绍如何在 Dokploy 中部署服务端数据库版 LobeChat。
17
+
18
+ ## 一、准备工作
19
+
20
+ ### 部署 Dokploy 并进行相关设置
21
+
22
+ ```shell
23
+ curl -sSL https://dokploy.com/install.sh | sh
24
+ ```
25
+
26
+ 1. 在 Dokploy 的 Settings / Git 处根据提示将 Github 绑定到 Dokploy
27
+
28
+ ![](https://github.com/user-attachments/assets/c75eb19e-e0f5-4135-91e4-55be8be8a996)
29
+
30
+ 2. 进入 Projects 界面创建一个 Project
31
+
32
+ ![](https://github.com/user-attachments/assets/4e04928d-0171-48d1-afff-e22fc2faaf4e)
33
+
34
+ ### 配置 S3 存储服务
35
+
36
+ 在服务端数据库中我们需要配置 S3 存储服务来存储文件,详细配置教程请参考 使用 Vercel 部署中 [配置 S3 储存服务](https://lobehub.com/zh/docs/self-hosting/server-database/vercel#%E4%B8%89%E3%80%81-%E9%85%8D%E7%BD%AE-s-3-%E5%AD%98%E5%82%A8%E6%9C%8D%E5%8A%A1)。配置完成后你将获得以下环境变量:
37
+
38
+ ```shell
32
39
  S3_ACCESS_KEY_ID=
33
40
  S3_SECRET_ACCESS_KEY=
34
41
  S3_ENDPOINT=
35
42
  S3_BUCKET=
36
43
  S3_PUBLIC_DOMAIN=
37
- S3_ENABLE_PATH_STYLE=
38
- ```
39
- ### 配置 Clerk 身份验证服务
40
- 获取 `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY` 、`CLERK_SECRET_KEY` 、`CLERK_WEBHOOK_SECRET` 这三个环境变量,Clerk的详细配置流程请参考 使用 Vercel 部署中 [配置身份验证服务](https://lobehub.com/zh/docs/self-hosting/server-database/vercel#二、-配置身份验证服务)
41
- ```shell
44
+ S3_ENABLE_PATH_STYLE=
45
+ ```
46
+
47
+ ### 配置 Clerk 身份验证服务
48
+
49
+ 获取 `NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY` 、`CLERK_SECRET_KEY` 、`CLERK_WEBHOOK_SECRET` 这三个环境变量,Clerk 的详细配置流程请参考 使用 Vercel 部署中 [配置身份验证服务](https://lobehub.com/zh/docs/self-hosting/server-database/vercel#二、-配置身份验证服务)
50
+
51
+ ```shell
42
52
  NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_live_xxxxxxxxxxx
43
53
  CLERK_SECRET_KEY=sk_live_xxxxxxxxxxxxxxxxxxxxxx
44
- CLERK_WEBHOOK_SECRET=whsec_xxxxxxxxxxxxxxxxxxxxxx
45
- ```
46
- ## 二、在 Dokploy 上部署数据库
47
- 进入前面创建的Project,点击 Create Service 选择 Database,在 Database 界面选择 PostgreSQL ,然后设置数据库名、用户、密码,在 Docker image 中填入 `pgvector/pgvector:pg17` 最后点击 Create 创建数据库。
48
-
49
- ![](https://github.com/user-attachments/assets/97899819-278f-42fd-804a-144d521d4b4f)
50
-
54
+ CLERK_WEBHOOK_SECRET=whsec_xxxxxxxxxxxxxxxxxxxxxx
55
+ ```
56
+
57
+ ## 二、在 Dokploy 上部署数据库
58
+
59
+ 进入前面创建的 Project,点击 Create Service 选择 Database,在 Database 界面选择 PostgreSQL ,然后设置数据库名、用户、密码,在 Docker image 中填入 `pgvector/pgvector:pg17` 最后点击 Create 创建数据库。
60
+
61
+ ![](https://github.com/user-attachments/assets/97899819-278f-42fd-804a-144d521d4b4f)
62
+
51
63
  进入创建的数据库,在 External Credentials 设置一个未被占用的端口,使其能能通过外部访问,否则 LobeChat 将无法连接到该数据库。
52
- 你可以在 External Host 查看 Postgres 数据库连接 URL ,如下:
53
- ```shell
54
- postgresql://postgres:wAbLxfXSwkxxxxxx@45.577.281.48:5432/postgres
55
- ```
56
- 最后点击 Deploy 部署数据库
57
-
58
- ![](https://github.com/user-attachments/assets/b4e89dd4-877b-43fe-aa42-4680de17ba8e)
59
-
60
- ## 在 Dokploy 上部署 LobeChat
61
- 点击 Create Service 选择 Application,创建 LobeChat 应用
62
-
63
- ![](https://github.com/user-attachments/assets/4cbbbcce-36be-48ff-bb0b-31607a0bba5c)
64
-
65
- 进入创建的 LobeChat 应用,选择你 fork 的 lobe-chat 项目及分支,点击 Save 保存
66
-
67
- ![](https://github.com/user-attachments/assets/2bb4c09d-75bb-4c46-bb2f-faf538308305)
68
-
69
- 切换到 Environment ,在其中填入环境变量,点击保存。
70
-
71
- ![](https://github.com/user-attachments/assets/0f79c266-cce5-4936-aabd-4c8f19196d91)
72
-
73
- ```shell
64
+ 你可以在 External Host 查看 Postgres 数据库连接 URL ,如下:
65
+
66
+ ```shell
67
+ postgresql://postgres:wAbLxfXSwkxxxxxx@45.577.281.48:5432/postgres
68
+ ```
69
+
70
+ 最后点击 Deploy 部署数据库
71
+
72
+ ![](https://github.com/user-attachments/assets/b4e89dd4-877b-43fe-aa42-4680de17ba8e)
73
+
74
+ ## 在 Dokploy 上部署 LobeChat
75
+
76
+ 点击 Create Service 选择 Application,创建 LobeChat 应用
77
+
78
+ ![](https://github.com/user-attachments/assets/4cbbbcce-36be-48ff-bb0b-31607a0bba5c)
79
+
80
+ 进入创建的 LobeChat 应用,选择你 fork 的 lobe-chat 项目及分支,点击 Save 保存
81
+
82
+ ![](https://github.com/user-attachments/assets/2bb4c09d-75bb-4c46-bb2f-faf538308305)
83
+
84
+ 切换到 Environment ,在其中填入环境变量,点击保存。
85
+
86
+ ![](https://github.com/user-attachments/assets/0f79c266-cce5-4936-aabd-4c8f19196d91)
87
+
88
+ ```shell
74
89
  # 构建所必需的环境变量
75
90
  NIXPACKS_PKGS="pnpm bun"
76
91
  NIXPACKS_INSTALL_CMD="pnpm install"
@@ -105,18 +120,19 @@ S3_ENABLE_PATH_STYLE=
105
120
  # OpenAI 相关配置
106
121
  OPENAI_API_KEY=
107
122
  OPENAI_MODEL_LIST=
108
- OPENAI_PROXY_URL=
109
- ```
110
- 添加完环境变量并保存后,点击 Deploy 进行部署,你可以在 Deployments 处查看部署进程及日志信息
111
-
112
- ![](https://github.com/user-attachments/assets/411e2002-61f0-4010-9841-18e88ca895ec)
113
-
114
- 部署成功后在 Domains 页面,为你的 LobeChat 应用绑定自己的域名并申请证书。
115
-
116
- ![](https://github.com/user-attachments/assets/dd6bc4a4-3c20-4162-87fd-5cac57e5d7e7)
117
-
118
- ## 验证 LobeChat 是否正常工作
119
- 进入你的 LobeChat 网址,如果你点击左上角登录,可以正常显示登录弹窗,那么说明你已经配置成功了,尽情享用吧~
120
-
121
- ![](https://github.com/user-attachments/assets/798ddb18-50c7-462a-a083-0c6841351d26)
122
-
123
+ OPENAI_PROXY_URL=
124
+ ```
125
+
126
+ 添加完环境变量并保存后,点击 Deploy 进行部署,你可以在 Deployments 处查看部署进程及日志信息
127
+
128
+ ![](https://github.com/user-attachments/assets/411e2002-61f0-4010-9841-18e88ca895ec)
129
+
130
+ 部署成功后在 Domains 页面,为你的 LobeChat 应用绑定自己的域名并申请证书。
131
+
132
+ ![](https://github.com/user-attachments/assets/dd6bc4a4-3c20-4162-87fd-5cac57e5d7e7)
133
+
134
+ ## 验证 LobeChat 是否正常工作
135
+
136
+ 进入你的 LobeChat 网址,如果你点击左上角登录,可以正常显示登录弹窗,那么说明你已经配置成功了,尽情享用吧~
137
+
138
+ ![](https://github.com/user-attachments/assets/798ddb18-50c7-462a-a083-0c6841351d26)