Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

使用 sealos nginx作为代理方案时,聊天发送消息后提示“self-signed certificate” #27

Closed
Textcat opened this issue May 10, 2023 · 7 comments

Comments

@Textcat
Copy link
Contributor

Textcat commented May 10, 2023

使用 sealos nginx作为代理方案时,聊天发送消息后提示“self-signed certificate”。
image

@c121914yu
Copy link
Collaborator

你好,这个问题应该是sealos自动签名证书问题。
请问是一开始就报错,还是后续报错?

可以浏览器直接访问: https://tgohwtdlrmer.cloud.sealos.io/openai/v1 看下https有没有错误提示,以及能不能收到响应。

@Textcat
Copy link
Contributor Author

Textcat commented May 11, 2023

浏览器访问sealos的外部地址,会有以下提示:

你的连接不是专用连接
攻击者可能试图从 ypqbhsfefwuf.cloud.sealos.io 窃取你的信息(例如,密码、消息或信用卡)。
NET::ERR_CERT_AUTHORITY_INVALID
Subject: Kubernetes Ingress Controller Fake Certificate

Issuer: Kubernetes Ingress Controller Fake Certificate

Expires on: 2024年3月29日

Current date: 2023年5月11日

@c121914yu
Copy link
Collaborator

可能是证书,没生效。可以去变更下nginx。
点击变更应用,点下更新应用

@Textcat
Copy link
Contributor Author

Textcat commented May 11, 2023

尝试了但是不行,nginx文件如下,是哪里写错了吗:

user nginx;
worker_processes auto;
worker_rlimit_nofile 51200;

events {
    worker_connections 1024;
}

http {
    resolver 8.8.8.8;
    proxy_ssl_server_name on;

    access_log off;
    server_names_hash_bucket_size 512;
    client_header_buffer_size 64k;
    large_client_header_buffers 4 64k;
    client_max_body_size 50M;

    proxy_connect_timeout       240s;
    proxy_read_timeout          240s;
    proxy_buffer_size 128k;
    proxy_buffers 4 256k;


    server {
        listen 80;
        server_name ypqbhsfefwuf.cloud.sealos.io; # 这个地方替换成 sealos 提供的内容

        location ~ /openai/(.*) {
            # auth check
            if ($http_auth != "auth") { # 安全凭证
                return 403;
            }

            proxy_pass https://api.openai.com/$1$is_args$args;
            proxy_set_header Host api.openai.com;
            proxy_set_header X-Real-IP $remote_addr;
            proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
            # 如果响应是流式的
            proxy_set_header Connection '';
            proxy_http_version 1.1;
            chunked_transfer_encoding off;
            proxy_buffering off;
            proxy_cache off;
            # 如果响应是一般的
            proxy_buffer_size 128k;
            proxy_buffers 4 256k;
            proxy_busy_buffers_size 256k;
        }
    }
}

@c121914yu
Copy link
Collaborator

应该没啥问题。不是很复杂。那估计是sealos那边有问题,我去他们群里问问

@c121914yu
Copy link
Collaborator

sealos回应已解决。可以尝试下

@Textcat
Copy link
Contributor Author

Textcat commented May 12, 2023

已经测试过,可以使用了。

@Textcat Textcat closed this as completed May 12, 2023
newfish-cmyk pushed a commit to newfish-cmyk/FastGPT that referenced this issue Feb 27, 2024
* feat: individuation page

* team chat config

* pay modal
c121914yu added a commit that referenced this issue Feb 28, 2024
* perf: insert mongo dataset data session

* perf: dataset data index

* remove delay

* rename bill schema

* rename bill record

* perf: bill table

* perf: prompt

* perf: sub plan

* change the usage count

* feat: usage bill

* publish usages

* doc

* 新增团队聊天功能 (#20)

* perf: doc

* feat 添加标签部分

feat 信息团队标签配置

feat 新增团队同步管理

feat team分享页面

feat 完成team分享页面

feat 实现模糊搜索

style 格式化

fix 修复迷糊匹配

style 样式修改

fix 团队标签功能修复

* fix 修复鉴权功能

* merge 合并代码

* fix 修复引用错误

* fix 修复pr问题

* fix 修复ts格式问题

---------

Co-authored-by: archer <545436317@qq.com>
Co-authored-by: liuxingwan <liuxingwan.lxw@alibaba-inc.com>

* update extra plan

* fix: ts

* format

* perf: bill field

* feat: standard plan

* fix: ts

* feat 个人账号页面修改 (#22)

* feat 添加标签部分

feat 信息团队标签配置

feat 新增团队同步管理

feat team分享页面

feat 完成team分享页面

feat 实现模糊搜索

style 格式化

fix 修复迷糊匹配

style 样式修改

fix 团队标签功能修复

* fix 修复鉴权功能

* merge 合并代码

* fix 修复引用错误

* fix 修复pr问题

* fix 修复ts格式问题

* feat 修改个人账号页

---------

Co-authored-by: liuxingwan <liuxingwan.lxw@alibaba-inc.com>

* sub plan page (#23)

* fix chunk index; error page text

* feat: dataset process Integral prediction

* feat: stand plan field

* feat: sub plan limit

* perf: index

* query extension

* perf: share link push app name

* perf: plan point unit

* perf: get sub plan

* perf: account page

* feat 新增套餐详情弹窗代码 (#24)

* merge 合并代码

* fix 新增套餐详情弹框

* fix 修复pr问题

* feat: change http node input to prompt editor (#21)

* feat: change http node input to prompt editor

* fix

* split PromptEditor to HttpInput

* Team plans (#25)

* perf: pay check

* perf: team plan test

* plan limit check

* replace sensitive text

* perf: fix some null

* collection null check

* perf: plans modal

* perf: http module

* pacakge (#26)

* individuation page and pay modal amount (#27)

* feat: individuation page

* team chat config

* pay modal

* plan count and replace invalid chars (#29)

* fix: user oneapi

* fix: training queue

* fix: qa queue

* perf: remove space chars

* replace invalid chars

* change httpinput dropdown menu (#28)

* perf: http

* reseet free plan

* perf: plan code to packages

* remove llm config to package

* perf: code

* perf: faq

* fix: get team plan

---------

Co-authored-by: yst <77910600+yu-and-liu@users.noreply.github.com>
Co-authored-by: liuxingwan <liuxingwan.lxw@alibaba-inc.com>
Co-authored-by: heheer <71265218+newfish-cmyk@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants