打开nginx的ssl_preread on,使nginx预处理ssl握手client hello字段,通过读取alpn字段为identifyssh(可自定义)字符串 判断出是ssh连接,否则(兼容非ssl连接)都是http连接,分别指向不同的upstream。
ssh 连接命令
ssh deploy@120.221.95.76 -o "ProxyCommand openssl s_client -alpn Qdeicc@9902 -ign_eof -connect 120.221.95.76:8086"



