Comments (6)
I have 0 knowledge of kotlin language. Did a quick search through out the source repository and found this function definition:
Seeing we are using the following API when establishing the websocket session:
Wondering whether this could be the culprit?
这么看起来的话,差不多就是我之前提的给ws反向连接添加一个tls_enabled配置就可以了
from onebot-kotlin.
I have 0 knowledge of kotlin language. Did a quick search through out the source repository and found this function definition:
https://github.com/ktorio/ktor/blob/master/ktor-client/ktor-client-core/common/src/io/ktor/client/features/websocket/builders.kt#L133
Seeing we are using the following API when establishing the websocket session:
https://github.com/yyuueexxiinngg/cqhttp-mirai/blob/master/src/main/kotlin/tech/mihoyo/mirai/web/websocket/WebsocketReverseClient.kt#L91
Wondering whether this could be the culprit?
from onebot-kotlin.
已在新版中添加支持 .如有BUG请reopen
from onebot-kotlin.
502 Bad Gateway的话,是不是你反代没配置好?
from onebot-kotlin.
502 Bad Gateway的话,是不是你反代没配置好?
反向代理的配置我感觉是没有问题的
配置如下
#PROXY-START/
location /
{
expires 12h;
if ($request_uri ~* "(php|jsp|cgi|asp|aspx)")
{
expires 0;
}
proxy_pass http://127.0.0.1:8002;
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 REMOTE-HOST $remote_addr;
#持久化连接相关配置
proxy_connect_timeout 30s;
proxy_read_timeout 86400s;
proxy_send_timeout 30s;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
add_header X-Cache $upstream_cache_status;
#Set Nginx Cache
proxy_ignore_headers Set-Cookie Cache-Control expires;
proxy_cache cache_one;
proxy_cache_key $host$uri$is_args$args;
proxy_cache_valid 200 304 301 302 1m;
}
#PROXY-END/
from onebot-kotlin.
你好,我遇到了相同的问题,以下是我的反代配置:
upstream backend{
server localhost:8080;
}
server
{
server_name subdomain.tld;
charset UTF-8;
access_log /var/log/nginx/uWSGI_access.log;
error_log /var/log/nginx/uWSGI_error.log;
client_max_body_size 75M;
location / {
proxy_pass http://backend;
proxy_redirect off;
proxy_http_version 1.1;
proxy_buffering off;
proxy_connect_timeout 30s;
proxy_read_timeout 600s;
proxy_send_timeout 30s;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location /static {
expires 30d;
autoindex on;
add_header Cache-Control private;
alias /home/ubuntu/project/static;
}
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/subdomain.tld/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/subdomain.tld/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
server
{
if ($host = subdomain.tld) {
return 301 https://$host$request_uri;
} # managed by Certbot
server_name subdomain.tld;
listen 80;
return 404; # managed by Certbot
}
将反向WebSocket 端口 更改成443 之后遇到了与 @a08381 相同的错误
from onebot-kotlin.
Related Issues (20)
- 登录QQ提示滑块验证请更换协议,换watch提示当前版本过低,要更新到 最新版 HOT 3
- [BUG]协议不规范? HOT 2
- [Question]如何开启gocq的长文本强制分节
- [BUG]无法区分群会话和群临时会话(群私聊)
- [Question] 配置文件中是否支持多个postUrl
- [BUG]图片上传提示插件无法获取到媒体 HOT 1
- [Question]1年没更了...uwu
- [Question]在和OlivOS配合使用时,打印以下错误日志
- 识别回复类信息时出现了报错[Question]
- [BUG]使用mcl进行操作的,升级到最新版的2.0beta后,报错上报的HTTP无法解析【已解决】 HOT 1
- 发送图片报错
- 发送图片报错
- [BUG]
- [Question]Websocket连接出错, 这是咋回事哇
- [BUG]通过http方式调用发送图片报错
- [Question]反向Websocket始终无法连接
- [BUG]mirai更新到v2.12.0后,加载本插件会导致mirai-http插件无法工作 HOT 1
- [BUG]onebot-mirai-0.3.4-all.jar报错导致机器人部分功能失效 HOT 1
- [BUG] 与 mirai-api-http 不兼容
- [Question]最近qq登陆不上了 238 235报错 求办法 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from onebot-kotlin.