📝 重置了deploy
下的文档
新添加了adapter.md用来转移配置器相关内容; 修改了部分文件的版权归属日期;
This commit is contained in:
@@ -7,29 +7,61 @@ order: 1
|
||||
|
||||
## **常规部署**
|
||||
|
||||
1. 安装 [`Git`](https://git-scm.com/download/) 和 [
|
||||
`Python3.10+`](https://www.python.org/downloads/release/python-31010/) 环境
|
||||
### 安装基本环境
|
||||
|
||||
```bash
|
||||
# 克隆项目到本地,轻雪使用Git进行版本管理,该步骤为必要项
|
||||
git clone https://github.com/LiteyukiStudio/LiteyukiBot --depth=1 # 若你不能访问Github,可以使用Liteyuki镜像:https://git.liteyuki.icu/bot/app
|
||||
**Git 版本管理工具**
|
||||
[Git](https://git-scm.com/download/)
|
||||
|
||||
# 切换到Bot目录下
|
||||
cd LiteyukiBot
|
||||
**Python3.10+**
|
||||
[Python3.10+](https://www.python.org/downloads/release/python-31010/)
|
||||
|
||||
# 创建虚拟环境
|
||||
python -m venv venv
|
||||
|
||||
# 激活虚拟环境
|
||||
.\venv\Scripts\activate # Windows
|
||||
source venv/bin/activate # Linux
|
||||
### 克隆项目到本地,轻雪使用Git进行版本管理,该步骤为必要项
|
||||
|
||||
# 安装依赖
|
||||
pip install -r requirements.txt
|
||||
`git clone https://github.com/LiteyukiStudio/LiteyukiBot --depth=1`
|
||||
|
||||
> 若你不能访问Github,可以使用Liteyuki镜像:`https://git.liteyuki.icu/bot/app`
|
||||
|
||||
### 切换到Bot目录下
|
||||
|
||||
`cd LiteyukiBot`
|
||||
|
||||
> 如果存在文件夹缺失报错, 尝试使用绝对路径进行路径跳转
|
||||
|
||||
### 创建虚拟环境
|
||||
|
||||
`python -m venv venv`
|
||||
|
||||
> 如果出现相关虚拟环境错误, 建议查询 [Python Venv](https://docs.python.org/3/library/venv.html)
|
||||
|
||||
|
||||
### 激活虚拟环境
|
||||
|
||||
Windows:
|
||||
`.\venv\Scripts\activate`
|
||||
|
||||
> 出现`'activate' 不是内部或外部命令,也不是可运行的程序或批处理文件。`错误, 请使用完整路径激活虚拟环境
|
||||
|
||||
Linux:
|
||||
`source venv/bin/activate`
|
||||
|
||||
> 如果出现`source: command not found`, 请使用完整路径激活虚拟环境
|
||||
|
||||
|
||||
### 安装依赖
|
||||
|
||||
`pip install -r requirements.txt`
|
||||
|
||||
> 若出现`ERROR: Could not open requirements file: [Errno 2] No such file or directory`错误, 请检查是否在Bot目录下执行命令
|
||||
|
||||
> 若出现`ERROR: Could not build wheels for xx, which is required to install pyproject.toml-based projects`错误,请尝试使用手动命令安装相关依赖(虚拟环境下执行`pip install xx`,例如`pip install Pillow`)
|
||||
|
||||
### 启动Bot
|
||||
|
||||
`python main.py`
|
||||
|
||||
> 若出现`ModuleNotFoundError: No module named 'xx'`错误, 请尝试重新执行安装依赖步骤
|
||||
|
||||
# 启动Bot
|
||||
python main.py
|
||||
```
|
||||
|
||||
## **使用Docker构建**
|
||||
|
||||
@@ -43,10 +75,15 @@ docker pull ghcr.io/liteyukistudio/liteyukibot:latest # 每夜版镜像
|
||||
|
||||
## **装置要求**
|
||||
|
||||
- Windows系统版本最低`Windows10+`/`Windows Server 2019+`
|
||||
- Windows系统版本推荐最低版本: `Windows 10 21H2` / `Windows Server 2019+`
|
||||
>版本低于`Windows 10 21H2` 可能无法正常使用Bot, 建议升级系统版本或使用Docker部署
|
||||
|
||||
- Linux系统要支持Python3.10+,推荐`Ubuntu 20.04+`(~~别用你那b CentOS~~)
|
||||
|
||||
- CPU: 至少`1vCPU`
|
||||
|
||||
- 内存: Bot无其他插件会占用`300~500MB`,包括`chromium` 及 `node`等进程,其他插件占用视具体插件而定,建议`1GB`以上
|
||||
|
||||
- 硬盘: 至少`1GB`空间
|
||||
|
||||
> [!warning]
|
||||
@@ -54,6 +91,6 @@ docker pull ghcr.io/liteyukistudio/liteyukibot:latest # 每夜版镜像
|
||||
> 为你的Python可执行文件路径
|
||||
|
||||
> [!warning]
|
||||
> 轻雪的更新功能依赖Git,如果你没有安装Git直接下载源代码运行,你将无法使用更新功能
|
||||
> 轻雪的更新功能依赖Git,如果你没有安装Git直接下载源代码运行,你将无法使用更新功能(除非你闲的手动下载源代码更新轻雪~~)
|
||||
|
||||
#### 其他问题请移步至[答疑](./fandq)
|
Reference in New Issue
Block a user