Archived
add_archive_project
This commit is contained in:
Executable
+22
@@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
|
||||
common_dir="/etc/xray/common"
|
||||
ipnet_dir="/etc/xray/ipnet"
|
||||
|
||||
sh $common_dir/check.sh
|
||||
|
||||
nft -f $common_dir/nft.conf
|
||||
sh $common_dir/prepare_domain.sh
|
||||
sh $common_dir/prepare_net.sh
|
||||
|
||||
for ipnet_file in "$ipnet_dir"/*; do
|
||||
[ -f "$ipnet_file" ] || continue
|
||||
if ! nft -f "$ipnet_file"; then
|
||||
logger -t xray-startup "$ipnet_file: apply failed"
|
||||
fi
|
||||
done
|
||||
|
||||
ip route show table 110 | grep -q "local default" || ip route add local default dev lo table 110
|
||||
ip rule show | grep -q "fwmark 0xa lookup 110" || ip rule add fwmark 10 table 110
|
||||
|
||||
service dnsmasq restart >/dev/null 2>&1
|
||||
Reference in New Issue
Block a user