lobehub / lobe-chat

🤯 Lobe Chat - an open-source, modern-design AI chat framework. Supports Multi AI Providers( OpenAI / Claude 3 / Gemini / Ollama / Qwen / DeepSeek), Knowledge Base (file upload / knowledge management / RAG ), Multi-Modals (Vision/TTS/Plugins/Artifacts). One-click FREE deployment of your private ChatGPT/ Claude application.
https://chat-preview.lobehub.com
Other
47.21k stars 10.37k forks source link

[Bug] #4883

Open liuluyanglly opened 11 hours ago

liuluyanglly commented 11 hours ago

📦 Environment

Docker

📌 Version

v1.35.10

💻 Operating System

Ubuntu

🌐 Browser

Edge

🐛 Bug Description

8000端口可以上传头像,但是3210端口这边。上传文档图片,都显示跨域。 image image

📷 Recurrence Steps

No response

🚦 Expected Behavior

No response

📝 Additional Information

No response

lobehubbot commented 11 hours ago

👀 @liuluyanglly

Thank you for raising an issue. We will investigate into the matter and get back to you as soon as possible. Please make sure you have given us as much context as possible.\ 非常感谢您提交 issue。我们会尽快调查此事,并尽快回复您。 请确保您已经提供了尽可能多的背景信息。

dosubot[bot] commented 11 hours ago

@liuluyanglly 你好! I'm here to help you with any bugs, questions, or contributions you have. Let's squash those bugs together! 🤖

I found a similar open issue related to CORS errors when uploading files. The suggested solution is to ensure that your CORS configuration in the Docker Compose setup for MinIO is correctly set. Specifically, the MINIO_API_CORS_ALLOW_ORIGIN environment variable should be set to your LobeChat's domain name. Additionally, you should check the MinIO WebUI under Configuration - API - Cors Allow Origin to ensure that the CORS settings are correctly applied [1].

The Docker Compose setup for MinIO is located in the docker-compose/local/docker-compose.yml file, and it is configured for CORS with the following environment variable:

environment:
  - 'MINIO_API_CORS_ALLOW_ORIGIN=http://localhost:${LOBE_PORT}'

This configuration allows CORS requests from the specified origin, which is http://localhost with the port defined by the LOBE_PORT environment variable [2].

To continue talking to Dosu, mention @dosu.

liuluyanglly commented 11 hours ago

加上了, 然后重启了, 结果还是一这样。换了个浏览器也一样。

lobehubbot commented 11 hours ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


I added it, then restarted, but the result is still the same. Same thing if I change the browser.