mirror of
https://github.com/NapNeko/NapCat-Docker.git
synced 2025-12-19 06:30:12 +08:00
chore: setup napcat at entrypoint (close #17)
This commit is contained in:
parent
3225de34e8
commit
14f03a7454
@ -15,6 +15,12 @@ chech_quotes(){
|
||||
CONFIG_PATH=napcat/config/onebot11_$ACCOUNT.json
|
||||
# 容器首次启动时执行
|
||||
if [ ! -f "$CONFIG_PATH" ]; then
|
||||
# 安装 napcat
|
||||
rarch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/x64/)
|
||||
unzip NapCat.linux.${rarch}.zip -d .
|
||||
mv NapCat.linux.${rarch} napcat
|
||||
chmod +x napcat/napcat.sh
|
||||
|
||||
if [ "$WEBUI_TOKEN" ]; then
|
||||
echo "{\"port\": 6099,\"token\": \"$WEBUI_TOKEN\",\"loginRate\": 3}" > napcat/config/webui.json
|
||||
fi
|
||||
|
||||
Loading…
Reference in New Issue
Block a user