autMan机器人安装教程【2023-6.4】


🔥推荐阅读:http://t.csdn.cn/nQfIY


前言

autMan机器人安装教程【2023-6.4】
准备:两个qq号、一台电脑、服务器(开放对应端口)

[video(video-4kwEQKeP-1685957504994)(type-csdn)(url-https://live.csdn.net/v/embed/301868)(image-https://live-file.csdnimg.cn/release/live/file/1685955599804.png?x-oss-process=image/resize,l_300)(title-🟢autMan视频安装教程🟢一镜到底、无剪辑)]

一、安装autMan

tag=$(curl -s https://gitee.com/hdbjlizhe/autMan/releases/latest|cut -d"\"" -f2|cut -d'/' -f8);if [ ! "$tag" ];then exit;fi;s=autMan;a=arm64;if [[ $(uname -a | grep "x86_64") != "" ]];then a=amd64;fi;if [ ! -d $s ];then mkdir $s;fi;cd $s;wget https://gitee.com/hdbjlizhe/${s}/releases/download/${tag}/autMan_$a.tar.gz && tar -zxvf autMan_$a.tar.gz && rm -rf autMan_$a.tar.gz && chmod 777 $s;pkill -9 $s;$(pwd)/$s -t;

1.进入autMan文件夹:cd /root/autMan
2.指令启动:./autMan -t
3. 静默:./autMan -d

二、安装Go

1️⃣下载文件

在这里插入图片描述

1、点击下载:go-cqhttp_windows_arm64.exe

📣如果你网速欠佳——群文件773633066下载

2️⃣本地运行

  • 为什么要在本地运行呢?
为了接下来在服务器一步成功,否则一定会出现,扫码异常(一定会出现)
  • 新建文件夹1,将下面文件放里面。

  • 在这里插入图片描述
    在这里插入图片描述

  • 进入文件夹1

  • 指令启动 autMan

.\\go-cqhttp_windows_amd64.exe -t
  • 修改autMan端口,默认为8080,不修改也可,要与config.js对应
set autMan port 9999
  • 选择3,然后回车,Ctrl+c结束进程
    在这里插入图片描述

  • 修改配置文件config.js

  • 账号密码反向链接
    在这里插入图片描述

在这里插入图片描述
在这里插入图片描述

ws://127.0.0.1:9999/qq/receive
127.0.0.1   //为服务器本地(指amtMan和go-cqHttp都在同一服务器)
9999        //为amtMan的端口

3️⃣重新启动go-cqHttp

  • 指令启动 gocqhttp
.\\go-cqhttp_windows_amd64.exe
  • 扫码登录 密码登录
  • 注意:确保登录环境在同一个WiFi,就是手机和电脑连同一个WiFi
    此时生成了两个文件device.jsonsession.token,后面会用到。
    在这里插入图片描述
    本地已经准备完毕,接下来转移到服务器操作!!!

4️⃣服务器下载go-cqhttp

  • 进入autMan根目录
cd autMan
  • 创建go-cqhttp文件夹并进入
mkdir go-cqhttp && cd go-cqhttp
  • 拉取go-cqhttp文件
wget https://github.com/Mrs4s/go-cqhttp/releases/download/v1.0.0-rc5/go-cqhttp_linux_amd64.tar.gz
  • 解压文件
tar -zxvf go-cqhttp_linux_amd64.tar.gz

5️⃣配置gocqhttp

配置gocqhttp,和前面本地一样,不累赘了

6️⃣启动go-cqhttp

本地文件夹生成两个文件device.jsonsession.token,把这两个放进服务器cqhttp文件里面,就是替换原来的,再次在服务器运行命令

  • 启动go-cqhttp
./go-cqhttp

不用扫码就可以登录了,因为session.token就是QQ秘钥信息,运行命令后就登录成功了

Ctrlc 结束进程

  • 后台运行
./go-cqhttp -d

结语

autMan机器人安装完成,如果失败多尝试几次,正常都可以成功!

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值