v1.8.4(未测试)

~全面适配singbox内核
~保守模式启动优化
~修复推荐任务每10分钟保存节点配置未生效的bug
This commit is contained in:
juewuy
2024-01-06 22:35:41 +08:00
parent 42a5474939
commit 101bbae2ba
10 changed files with 849 additions and 437 deletions

30
scripts/shellcrash.rc Normal file
View File

@@ -0,0 +1,30 @@
#!/bin/sh /etc/rc.common
START=99
SERVICE_DAEMONIZE=1
SERVICE_WRITE_PID=1
USE_PROCD=1
#获取目录
CRASHDIR=$(cat /etc/profile | grep CRASHDIR | awk -F "\"" '{print $2}')
[ -z "$CRASHDIR" ] && CRASHDIR=$(cat ~/.bashrc | grep CRASHDIR | awk -F "\"" '{print $2}')
BINDIR=$(cat $DIR/configs/ShellCrash.cfg | grep bindir | awk -F "=" '{print $2}')
[ -z "$BINDIR" ] && BINDIR=$DIR
source $DIR/configs/service.env
start_service() {
#检测必须文件
$CRASHDIR/start.sh bfstart
if [ "$?" = "0" ];then
#使用procd创建clash后台进程
procd_open_instance
procd_set_param respawn
procd_set_param stderr 0
procd_set_param stdout 0
procd_set_param command $COMMAND
procd_close_instance
#其他设置
$CRASHDIR/start.sh afstart
fi
}