当前页面是本站的「Baidu MIP」版。发表评论请点击:完整版 »

v2ray配置 WebSocket+TLS+Nginx(更新)

2019-01-09T21:42:53

前面写过一篇关于v2ray的文章本次只是更新一下

2ray配置 WebSocket+TLS+Nginx

环境配置

v2ray 4.10.0
bt 6.8.8

v2ray配置

{
  "inbounds": [{
    "port": 39005, //自行修改
    "protocol": "vmess",
    "settings": {
      "clients": [
        {
          "id": "e4836bef-487b-8e56-91c106e74870", //自行修改
          "level": 1,
          "alterId": 64
        }
      ]
    },
  "streamSettings": {
      "network": "ws", 
      "security": "auto", 
      "wsSettings": {
        "path": "/PATH/", 
        "headers": {
          "Host": "klxzl.cn"   //自行修改
        }
      }
    }
  }],
  "outbounds": [{
    "protocol": "freedom",
    "settings": {}
  },{
    "protocol": "blackhole",
    "settings": {},
    "tag": "blocked"
  }],
  "routing": {
    "rules": [
      {
        "type": "field",
        "ip": ["geoip:private"],
        "outboundTag": "blocked"
      }
    ]
  }
}

宝塔配置

直接新建网站
然后开启ssl并强制https
在创建反向代理如图

然后编辑反向代理配置文件
去掉配置的#号如图

proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";


然后就可以用v2rayN连接了

当前页面是本站的「Baidu MIP」版。发表评论请点击:完整版 »