Update sb.sh
This commit is contained in:
@@ -1025,9 +1025,9 @@ fi
|
||||
hy2_port=$(sed 's://.*::g' /etc/s-box/sb.json | jq -r '.inbounds[2].listen_port')
|
||||
hy2_ports=$(iptables -t nat -nL --line 2>/dev/null | grep -w "$hy2_port" | awk '{print $8}' | sed 's/dpts://; s/dpt://' | tr '\n' ',' | sed 's/,$//')
|
||||
if [[ -n $hy2_ports ]]; then
|
||||
hy2ports=$(echo $hy2_ports | sed 's/:/-/g')
|
||||
hyps=$hy2ports
|
||||
sbhy2pt=(echo "$hy2_ports" | grep -o '[0-9]\+:[0-9]\+' | sed 's/.*/"&"/' | paste -sd,)
|
||||
cmhy2pt=$(echo $hy2_ports | tr ':' '-')
|
||||
hyps=$cmhy2pt
|
||||
sbhy2pt=$(echo "$hy2_ports" | grep -o '[0-9]\+:[0-9]\+' | sed 's/.*/"&"/' | paste -sd,)
|
||||
else
|
||||
hyps=
|
||||
fi
|
||||
@@ -1576,7 +1576,8 @@ proxies:
|
||||
- name: hysteria2-$hostname
|
||||
type: hysteria2
|
||||
server: $cl_hy2_ip
|
||||
port: $hy2_port
|
||||
port: $hy2_port
|
||||
ports: $cmhy2pt
|
||||
password: $uuid
|
||||
alpn:
|
||||
- h3
|
||||
|
||||
Reference in New Issue
Block a user