配置gateway 完成以后 用http協議可以訪問連接 ws協議連接失敗
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
location /wss {
proxy_pass http://127.0.0.1:2348;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
可以正常啟動
ws協議連接失敗
http協議可以訪問