nginx反向代理tomcat websocket配置

location /websocket {
            proxy_http_version 1.1;
            proxy_set_header Host host;
            proxy_set_header X-Real-IP $remote_addr;
            proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
            proxy_set_header Cookie $http_cookie;
            proxy_set_header Upgrade $http_upgrade;
            proxy_set_header Connection "upgrade";
            proxy_pass http://127.0.0.1:8081/g07-web/ws;
}

©️2020 CSDN 皮肤主题: 大白 设计师:CSDN官方博客 返回首页