支持自定义BOT仓库 (#1051)

This commit is contained in:
Chiupam
2022-01-04 13:26:16 +08:00
committed by GitHub
parent f3ecf6e7a0
commit 653b1cef20
2 changed files with 15 additions and 6 deletions
+3
View File
@@ -35,6 +35,9 @@ EnableExtraShell="true"
## 是否自动启动bot,默认不启动,设置为true时自动启动,目前需要自行克隆bot仓库所需代码,存到ql/repo目录下,文件夹命名为dockerbot
AutoStartBot=""
## 是否使用第三方bot,默认不使用,使用时填入仓库地址,存到ql/repo目录下,文件夹命名为diybot
BotRepoUrl=""
## 安装bot依赖时指定pip源,默认使用清华源,如不需要源,设置此参数为空
PipMirror="https://pypi.tuna.tsinghua.edu.cn/simple"
+6
View File
@@ -3,8 +3,14 @@
## 导入通用变量与函数
dir_shell=/ql/shell
. $dir_shell/share.sh
if [[ -z ${BotRepoUrl} ]]; then
url="${github_proxy_url}https://github.com/SuMaiKaDe/bot.git"
repo_path="${dir_repo}/dockerbot"
else
url=${BotRepoUrl}
repo_path="${dir_repo}/diybot"
fi
echo -e "\n1、安装bot依赖...\n"
apk --no-cache add -f zlib-dev gcc jpeg-dev python3-dev musl-dev freetype-dev