~修复小米设备开启自启失败的问题
~修复本机代理nftables增强模式部分情况下无法代理docker流量的问题
~修复本机代理iptables提示重复添加的问题
This commit is contained in:
juewuy
2023-07-31 21:25:11 +08:00
parent d54b6df7f7
commit 4ec7a5dda1
10 changed files with 77 additions and 76 deletions

View File

@@ -10,7 +10,6 @@ DIR=$(cat /etc/profile | grep clashdir | awk -F "\"" '{print $2}')
[ -z "$DIR" ] && DIR=$(cat ~/.bashrc | grep clashdir | awk -F "\"" '{print $2}')
BINDIR=$(cat $DIR/configs/ShellClash.cfg | grep bindir | awk -F "=" '{print $2}')
[ -z "$BINDIR" ] && BINDIR=$DIR
TMPDIR=/tmp/clash_$USER
start_service() {
#检测必须文件
@@ -21,7 +20,7 @@ start_service() {
procd_set_param respawn
procd_set_param stderr 0
procd_set_param stdout 0
procd_set_param command $BINDIR/clash -d $BINDIR -f $TMPDIR/config.yaml
procd_set_param command $BINDIR/clash -d $BINDIR
procd_close_instance
#其他设置
$DIR/start.sh afstart
@@ -34,7 +33,7 @@ start() {
$DIR/start.sh bfstart
if [ "$?" = "0" ];then
#创建后台进程
service_start $BINDIR/clash -d $BINDIR -f $TMPDIR/config.yaml
service_start $BINDIR/clash -d $BINDIR
#其他设置
$DIR/start.sh afstart
#设置守护进程