https://github.com/ttionya/mirai-http-docker
QQ bot Mirai with "mirai-api-http" plugin
https://github.com/ttionya/mirai-http-docker
Last synced: 6 months ago
JSON representation
QQ bot Mirai with "mirai-api-http" plugin
- Host: GitHub
- URL: https://github.com/ttionya/mirai-http-docker
- Owner: ttionya
- License: mit
- Created: 2021-08-22T08:16:59.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2023-10-19T15:19:05.000Z (almost 2 years ago)
- Last Synced: 2023-10-19T16:25:31.918Z (almost 2 years ago)
- Language: Shell
- Size: 15.4 MB
- Stars: 8
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# mirai-http
[](https://hub.docker.com/r/ttionya/mirai-http/tags) [](https://hub.docker.com/r/ttionya/mirai-http) [](https://github.com/ttionya/mirai-http-docker/blob/master/LICENSE)
集成了 `mirai-api-http` 插件的 Mirai QQ 机器人 Docker 镜像。
## 使用方法
你需要先进入要存放 Mirai 配置的目录。
若使用 `docker-compose`,请下载 `docker-compose.yml` 文件到当前目录。
### 1. 生成配置文件并修改
```shell
docker run \
--rm -it \
--mount type=bind,source=$(pwd)/config,target=/mirai/config \
-e LANG="C.UTF-8" \
ttionya/mirai-http:latest# 或使用 docker-compose
docker-compose up
```出现 `mirai-console started successfully` 后 `Ctrl + C` 终止运行。
并根据实际情况修改 `config` 中的配置文件。
### 2. 验证
执行以下指令确认可以正常登录账号。
```shell
docker run \
--rm -it \
--mount type=bind,source=$(pwd)/bots,target=/mirai/bots \
--mount type=bind,source=$(pwd)/config,target=/mirai/config \
--mount type=bind,source=$(pwd)/data,target=/mirai/data \
-e LANG="C.UTF-8" \
ttionya/mirai-http:latest# 或使用 docker-compose
docker-compose run --rm mirai-http
```出现 `Bot login successful` 相关内容后代表账号登录成功,可以通过 `Ctrl + C` 终止运行。
### 3. 后台运行
```shell
docker run -d \
--restart=always \
--name mirai-http \
--mount type=bind,source=$(pwd)/bots,target=/mirai/bots \
--mount type=bind,source=$(pwd)/config,target=/mirai/config \
--mount type=bind,source=$(pwd)/data,target=/mirai/data \
-p 127.0.0.1:8080:8080 \
-e LANG="C.UTF-8" \
ttionya/mirai-http:latest# 或使用 docker-compose
docker-compose up -d
```
## 插件
内置插件及版本信息详见 [Plugins](/plugins/README.md)。
## 关联项目
- [Mirai](https://github.com/mamoe/mirai)
- [iTXTech MCL Installer](https://github.com/iTXTech/mcl-installer)
- [Mirai Console Loader](https://github.com/iTXTech/mirai-console-loader)
## 许可证
MIT