/ linux

VMess

install

https://toutyrater.github.io/prep/install.html

config

https://toutyrater.github.io/prep/vmess.html

UUID Generator

现已支持 http2

nginx.conf

server {
    listen 443 http2 ssl;
    server_name xxxxxxxxxxxxxxxxxxxxx;
    ssl on;
    ssl_certificate /etc/nginx/conf.d/1_xxxx.com_bundle.crt;
    ssl_certificate_key /etc/nginx/conf.d/2_xxxx.com.key;
    ssl_session_timeout 5m;
    ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
    ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
    ssl_prefer_server_ciphers on;

    location / {

        proxy_redirect off;
        proxy_pass http://127.0.0.1:xxxxx;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_set_header Host $http_host;

        # Show realip in v2ray access.log
        # proxy_set_header X-Real-IP $remote_addr;
        # proxy_set_header Host $host;
        # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;

    }
}

v2ray/config.json

{
  "log":{
    "access":"/var/log/v2ray/access.log",
    "error":"/var/log/v2ray/error.log",
    "loglevel":"warning"
  },
  "inbounds": [{
    "port": xxxxx,
    "protocol": "vmess",
    "settings": {
      "clients": [
        {
          "id": "xxxxxxxxxxxxxxxxxxxxxx",
          "level": 1,
          "alterId": 64
        }
      ]
    },"streamSettings": {
        "network": "ws",
        "security": "auto",
        "wsSettings": {
          "path": "/"
        }
      }
  }],
  "outbounds": [{
    "protocol": "freedom",
    "settings": {}
  }]
}

note

systemctl status v2ray 查看服务状态
systemctl restart v2ray 重启服务
systemctl stop v2ray 停止服务
systemctl start v2ray 启动服务