增加启动脚本, 初始化脚本不再打印分享链接,

This commit is contained in:
Kiolow
2024-12-15 21:02:02 +08:00
parent b80d7dc367
commit 544eb665b8
2 changed files with 30 additions and 5 deletions
+18
View File
@@ -0,0 +1,18 @@
#!/bin/bash
script_dir=$(cd "$(dirname "$0")"; pwd) # 脚本文件绝对路径
config_dir=$(readlink -f "$script_dir/../conf") # 配置文件绝对路径
uuid=$(jq -r '.inbounds[0].settings.clients[0].id' $config_dir/config.json)
# 如果配置未初始化
if [ $uuid = "你的UUID" ]; then
# 执行初始化脚本
bash $script_dir/init.sh
fi
## 启动docker容器
docker-compose up -d -f $script_dir/../docker-compose.yml
# 打印分享链接
bash $script_dir/print_share_link.sh