This commit is contained in:
Olia Lisa
2025-08-15 21:43:15 +08:00
parent 5cab57adf4
commit e3801150c0
6 changed files with 89 additions and 14 deletions
+12 -8
View File
@@ -20,22 +20,26 @@ ipv4=$(curl -4 -sSL --connect-timeout 3 --retry 2 ip.sb || echo "null")
uuid=$(jq -r '.inbounds[0].settings.clients[0].id' $config_dir/config.json)
port=$(jq -r '.inbounds[0].port' $config_dir/config.json)
target=$(jq -r '.inbounds[0].streamSettings.realitySettings.target' $config_dir/config.json)
sni=$(echo $target | awk -F ':' '{print $1}')
dest=$(jq -r '.inbounds[0].streamSettings.realitySettings.dest' $config_dir/config.json)
sni=$(echo $dest | awk -F ':' '{print $1}')
network="tcp"
public_key=$(cat $config_dir/key.txt | grep "Public" | awk -F ': ' '{print $2}')
# 打印配置信息
echo -e "\033[32m" # config info with green color
echo "IPV4: $ipv4"
echo "PORT: $port"
echo "UUID: $uuid"
echo "SNI: $sni"
echo "PUBLIC_KEY: $public_key"
echo "NETWORK: $network"
echo "ipv4: $ipv4"
echo "port: $port"
echo "uuid: $uuid"
echo "dest: $dest"
echo "sni: $sni"
echo "public_key: $public_key"
echo "network: $network"
if [ "$ipv4" != "null" ]; then
sub_ipv4="vless://$uuid@$ipv4:$port?encryption=none&security=reality&type=$network&sni=$sni&fp=chrome&pbk=$public_key&flow=xtls-rprx-vision#my_docker_vless_reality_vision"
echo ""
echo "IPV4 订阅连接: $sub_ipv4"
echo ""
# 如果qrencode安装了,则打印二维码
if command -v qrencode &> /dev/null; then
echo -e "IPV4 订阅二维码:\n$(echo "$sub_ipv4" | qrencode -o - -t UTF8)"