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

Go-cqhttp如何配置 #9

Open
red0700 opened this issue Nov 30, 2021 · 3 comments
Open

Go-cqhttp如何配置 #9

red0700 opened this issue Nov 30, 2021 · 3 comments

Comments

@red0700
Copy link

red0700 commented Nov 30, 2021

你好,我在vps上启动Go-cqhttp和bot.py后,它们可以独立的运行但是不能进行交互,其中http和正反向ws都进行过尝试,但都不行,请问Go-cqhttp和env的配置文件能让我参考一下嘛?我想知道ip和端口的配置是怎样的。

@490720818
Copy link

image
image

@JustUndertaker
Copy link
Owner

image image

gocq需要修改以下配置:
1.default-middlewares:
access-token: '' 需要与项目.env.prod里面的access_token保持一致(如果不填可以将.env.prod的此项删除)
2.message:
post-format: array 上报信息改为数组,目前没用CQ码
3.servers:
- ws-reverse:
universal:ws://127.0.0.1:8080/cqhttp/ws 这里地址和端口与.env.prod的地址端口一致即可
#api: ws://your_websocket_api.server 在gocq-beta8以上版本时,需要将后面api和event地址注释掉。
#event: ws://your_websocket_event.server

@red0700
Copy link
Author

red0700 commented Dec 1, 2021

非常感谢,问题解决啦!

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

3 participants