apache httpd failed: Error during WebSocket handshake: Unexpected response 400

mac2024-04-11  65

apache httpd failed: Error during WebSocket handshake: Unexpected response 400

项目在单机环境下测试连接socket运行正常,后转入apache上部署出现异常,检测发现在配置apache时开启socket握手失败,由于httpd转向失败,浏览器报错failed: Error during WebSocket handshake: Unexpected response 400

找到/etc目录下的httpd.conf 配置文件 (找到你的httpd.conf 文件就行了)

在底部加入

<Location /fio/volume/test/start> ProxyPass ws://127.0.0.1:8080/fio/volume/test/start ProxyPassReverse wss://127.0.0.1:8080/fio/volume/test/start </Location>

proxypass和ProxyPassReverse 的用法含义在官网文档上有详细

proxypass和ProxyPassReverse

最新回复(0)