[Bug] nextchat v2.16.1 版本,使用nginx 反代后,chat 无响应
📦 部署方式
Docker
📌 软件版本
2.16.1
💻 系统环境
Other Linux
📌 系统版本
Debian 6.1.140-1
🌐 浏览器
Chrome
📌 浏览器版本
137.0.7151.105
🐛 问题描述
不用 nginx 反代,直接使用http://x.x.x.x:3000 访问,正常。使用 nginx 反代, 用https://x.x.x.x:3000 访问,对话无响应(见图)。但如果docker 镜像切换为 2.15.8 版本,则一切功能正常。 现象和 #6537 一样,但 #6537 提供的解决方案无效。
反代配置如下:
location / {
proxy_pass http://127.0.0.1:3000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Host $host;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
📷 复现步骤
使用docker 运行,服务端口 127.0.0.1:3000, 使用 nginx 反代,外网端口3000, 假定域名 nextchat.abc.xyz, 用 https://nextchat.abc.xyz:3000 访问,对话无响应。(排除访问密码错误问题, base_url, api_key 等问题)
🚦 期望结果
希望新版本能和 v2.15.8一样能正常使用nginx 反代。
📝 补充信息
No response
Bot detected the issue body's language is not English, translate it automatically.
Title: [Bug] nextchat v2.16.1 version, chat has no response after using nginx anti-generation
我遇到了类似的情况;自己设置了 alphine 阻止爬虫。 用在主机上的 Nginx访问没问题,但是走另一个容器上的 Nginx 去访问,也会出现不响应。
Bot detected the issue body's language is not English, translate it automatically.
I encountered a similar situation; I set up alphine to stop crawlers myself. It is fine to use Nginx access on the host, but if you go to Nginx on another container to access it, there will be no response.
你怎么成功的 我v2.16.1用docker创建后 测试deepseek的api 一直把我的CODE当作api传过去 一直api认证失败
Bot detected the issue body's language is not English, translate it automatically.
How did you succeed? After I created v2.16.1 with docker, I tested the deepseek API. I have been passing my CODE as API. I have been passing it over. The API authentication has been failing.