1. 开启apache 模块(软件管理=》apache=>设置)

LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so

2.修改网站配置文件,在#php 加入这句,记得是443端口的配置部分

   RewriteEngine On
        RewriteCond %{HTTP:Connection} Upgrade [NC]
        RewriteCond %{HTTP:Upgrade} websocket [NC]
        RewriteRule /(.*) ws://127.0.0.1:10550/$1 [P,L]
 
        ProxyRequests off
        <Location /random >
            ProxyPass http://127.0.0.1:10550/
            ProxyPassReverse /
        </Location>
    #PHP


标签: none

添加新评论