这篇文章上次修改于 1079 天前,可能其部分内容已经发生变化,如有疑问可询问作者。

中转比较简单,可以解决速度慢的问题。比如说你有 VPS1 和 VPS2 这两个服务器,发现 VPS1 可以看 Netflix,但是速度慢,VPS2 速度不错,但是看不了 Netflix。再加上通常来说国外 VPS 之间的速度不会太差,所以我们可以在 VPS2 做中转,属于 Netflix 的流量就转发到 VPS1,其他流量就直连。这种方式在国内中转介绍过。以下是 VPS2 的配置示例,客户端连接 VPS2 即可。

第一步,在VPS1上新建一个入站账号,

第二步,在VPS2上修改设置

{
  "api": {
    "services": [
      "HandlerService",
      "LoggerService",
      "StatsService"
    ],
    "tag": "api"
  },
  "inbounds": [
    {
      "listen": "127.0.0.1",
      "port": 62789,
      "protocol": "dokodemo-door",
      "settings": {
        "address": "127.0.0.1"
      },
      "tag": "api"
    }
  ],
  "outbounds": [
    {
      "protocol": "freedom",
      "settings": {}
    },
    {
      "protocol": "blackhole",
      "settings": {},
      "tag": "blocked"
    },
    {
      "tag": "VPS1",   //vps1设置
      "protocol": "vmess",
      "settings": {
        "vnext": [{
          "address": "1.2.3.4", 
          "port": 1234,
          "users": [{
            "id": "ea886794-fd26-4ad9-ce97-743f3d5eafd",
            "security": "auto",
            "alterId": 0
          }]
        }]
      }
    }
    
  ],
  "policy": {
    "system": {
      "statsInboundDownlink": true,
      "statsInboundUplink": true
    }
  },
  "routing": {
    "rules": [
      {
        "inboundTag": [
          "api"
        ],
        "outboundTag": "api",
        "type": "field"
      },
      {
        "ip": [
          "geoip:private"
        ],
        "outboundTag": "blocked",
        "type": "field"
      },
      {
        "outboundTag": "blocked",
        "protocol": [
          "bittorrent"
        ],
        "type": "field"
      },
      {
        "type": "field",
        "outboundTag": "VPS1",
        "domain": ["geosite:netflix"]   
// netflix 走 VPS1
      }
    ]
  },
  "stats": {}
}