diff --git a/mtproxy.sh b/mtproxy.sh index 04250e6..74b18cc 100644 --- a/mtproxy.sh +++ b/mtproxy.sh @@ -424,10 +424,11 @@ function get_run_command(){ domain_hex=$(str_to_hex $domain) client_secret="ee${secret}${domain_hex}" local local_ip=$(get_local_ip) + public_ip=$(get_ip_public) # ./mtg simple-run -n 1.1.1.1 -t 30s -a 512kib 0.0.0.0:$port $client_secret >/dev/null 2>&1 & [[ -f "./mtg" ]] || (echo -e "提醒:\033[33m MTProxy 代理程序不存在请重新安装! \033[0m" && exit 1) - echo "./mtg run $client_secret $proxy_tag -b 0.0.0.0:$port --multiplex-per-connection 500 --prefer-ip=ipv6 -t $local_ip:$web_port" + echo "./mtg run $client_secret $proxy_tag -b 0.0.0.0:$port --multiplex-per-connection 500 --prefer-ip=ipv6 -t $local_ip:$web_port" -4 "$public_ip:$port" else curl -s https://core.telegram.org/getProxyConfig -o proxy-multi.conf curl -s https://core.telegram.org/getProxySecret -o proxy-secret