v2ray & Trojan Deployment
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 25/100
- issue の種類
- ドキュメント
- 明瞭さ
- 説明が足りない
- 活発さ
- 停滞
- 技術スタック
- docker, linux, nginx, raspberry-pi
調査の方向性
The issue names no repository file, test, or entry point; first inspect the repository's contribution and documentation structure to find where deployment tips belong. Confirm the proposed V2Ray and Trojan instructions, links, platform coverage, and configuration examples are suitable for the project before adding the guide.
索引モデルが issue の本文から書いたものです。
説明
1.服务端一键安装
https://malagege.github.io/blog/2021/03/28/%E5%9C%A8-Raspberry-Pi-%E5%BB%BA%E7%BD%AE-V2ray/
https://uzbox.com/v2raydown.html
bash <(curl -sL https://raw.githubusercontent.com/hiifeng/v2ray/main/install_v2ray.sh)
2.使用 Docker 来部署 V2Ray Server
https://malagege.github.io/blog/2021/03/28/%E5%9C%A8-Raspberry-Pi-%E5%BB%BA%E7%BD%AE-V2ray/
https://github.com/alphacodinghub/v2ray-nginx-docker
3.Trojan docker 服务端搭建(支持 Arm64, Arm64v8,RPI 4B 是 Arm64v8):
https://hub.docker.com/r/teddysun/trojan
4.Linux 客户端
linux 客户端安装(树莓派通用):
https://github.com/v2fly/fhs-install-v2ray
https://dm116.github.io/2020/04/01/configuration-of-v2ray-client-and-server-with-cdn/
https://programmer.ink/think/linux-raspberry-pie-installation-v2ray-client.html
curl -L https://raw.githubusercontent.com/v2fly/fhs-install-v2ray/master/install-release.sh
chmod +x install-release.sh
###指定局域网代理来安装 Linux 客户端:
./install-release.sh -p http://192.168.1.20:7890
在 PC(或手机)中,配置 V2Ray 客户端:
vim /usr/local/etc/v2ray/config.json
{
"log": {
"loglevel": "warning",
"access": "/var/log/v2ray/access.log",
"error": "/var/log/v2ray/error.log"
},
// in
"inbounds": [
{
"port": 1081,
"protocol": "socks",
"sniffing": {
"enabled": true,
"destOverride": ["http", "tls"]
},
"settings": {
"auth": "noauth",
"udp": true
}
},
{
"port": 1080,
"protocol": "http",
"sniffing": {
"enabled": true,
"destOverride": ["http", "tls"]
},
"settings": {
"auth": "noauth",
"udp": false
}
}
],
// out
"outbounds": [
{
"tag":"proxy",
"protocol":"vmess",
"settings": {
"vnext": [
{
"address": "myvmserver.com",
"port": 443,
"users": [
{
"id": "xxxx-43bd-4749-bd60-xxxx",
"alterId": 16
}
]
}
]
},
"streamSettings": {
"network": "ws",
"security": "tls",
"wsSettings": {
"path": "/serverpath"
}
},
"mux": {
"enabled": true
}
},
{
"protocol": "freedom",
"settings":{},
"tag": "direct"
},
{
"protocol": "blackhole",
"settings":{},
"tag": "adblock"
}
],
// route
"routing": {
"domainStrategy": "IPOnDemand",
"rules": [
{
"type": "field",
"outboundTag": "adblock",
"domain": [
"tanx.com",
"googeadsserving.cn",
"baidu.com"
]
},
{
"type": "field",
"outboundTag": "direct",
"ip": [
"geoip:cn", // 中国大陆的 IP
"geoip:private" // 私有地址 IP,如路由器等
]
},
{
"type": "field",
"outboundTag": "direct",
"domain": [
"geosite:cn", // 中国大陆主流网站的域名
"domain:baidu.com",
"domain:taobao.com",
"domain:aliyun.com",
"domain:zhihu.com",
"domain:cnblogs.com",
"domain:runoob.com",
"domain:freebuf.com",
"domain:mozilla.org",
"domain:csdn.net",
"domain:jd.com"
]
}
]
}
}
启动服务
systemctl enable v2ray; systemctl start v2ray
上述配置要更改的地方是你的 vmess 服务器 address,id, alterId, wsSettings 里面的 path。上述配置会把除局域网(比如访问路由器)以外的所有流量转发至你的服务器。
在 Windows 和 macOS 中,配置文件通常是 V2Ray 同目录下的 config.json 文件。直接运行 v2ray 或 v2ray.exe 即可。
在 Linux 中,配置文件通常位于 /etc/v2ray/ 或 /usr/local/etc/v2ray/ 目录下。运行 v2ray --config=/etc/v2ray/config.json,或使用 systemd 等工具将 V2Ray 作为服务在后台运行。
更多详细的说明可以参考 配置文档 和 新白话文指南 .
验证 Proxy 是否工作(12.34.56.74 为 v2ray server地址):
$ curl -sSx socks5h://127.0.0.1:1081 http://ifconfig.co
12.34.56.78
$ curl -sSx http://127.0.0.1:1080 http://ifconfig.co
12.34.56.78
$ curl https://www.google.com
如果出现这个错误, 检测服务器端的 SSL 证书是否过期。
OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to xxx
5.Mac ClashX 客户端配置
新版语法
# VMess
- name: "v2ray"
type: vmess
server: xx.xx.xx.yy
port: 443
uuid: zzzzzzz-tttt-zzzz-xxxxxx-xxxxxxx
alterId: 16
cipher: auto
udp: true
tls: true
skip-cert-verify: true
# tls-hostname: myvmserver.com
network: ws
ws-opts:
path: /serverpath
headers:
Host: myvmserver.com
6.VLESS 一键安装
bash <(curl -sL https://raw.githubusercontent.com/hiifeng/v2ray/main/install_v2ray.sh)
7.V2rayU 客户端 的 vless + TLS + WS 配置
在 V2rayU 的配置里面,粘贴 json 配置,更改其中的 domain_name 为 vless 服务器域名, id 为 uuid, ws 的 path 为服务端路径即可。
{
"inbounds": [
{
"port": 1080,
"listen": "127.0.0.1",
"protocol": "socks",
"settings": {
"udp": true
}
},
{
"port": 1090,
"listen": "127.0.0.1",
"protocol": "http",
"sniffing": {
"enabled": true,
"destOverride": ["http", "tls"]
},
"settings": {
"auth": "noauth",
"udp": false
}
}
],
"outbounds": [
{
"protocol": "vless",
"settings": {
"vnext": [
{
"address": "domain_name.com",
"port": 443,
"users": [
{
"id": "xxxx-b5f2-4641-bdc0-xxxx",
"encryption": "none"
}
]
}
]
},
"streamSettings": {
"network": "ws",
"security": "tls",
"tlsSettings": {
"serverName": "domain_name.com"
},
"wsSettings": {
"path": "/xxx"
}
}
}
]
}
同时配置 HTTP/Socket 的本地代理:
https://iitii.github.io/2020/02/04/1/
8.VMess 客户端 JSON 配置 (For Linux host v2ray, V2RayU on Mac/Linux)
https://dm116.github.io/2020/04/01/configuration-of-v2ray-client-and-server-with-cdn/
{
"log": {
"error": "",
"loglevel": "info",
"access": ""
},
"inbounds": [
{
"listen": "127.0.0.1",
"protocol": "socks",
"settings": {
"udp": false,
"auth": "noauth"
},
"port": "7890"
},
{
"listen": "127.0.0.1",
"protocol": "http",
"settings": {
"timeout": 360
},
"port": "1090"
}
],
"outbounds": [
{
"mux": {
"enabled": false,
"concurrency": 8
},
"protocol": "vmess",
"streamSettings": {
"wsSettings": {
"path": "/xxxxxxxx",
"headers": {
"host": ""
}
},
"tlsSettings": {
"allowInsecure": false
},
"security": "tls",
"network": "ws"
},
"tag": "proxy",
"settings": {
"vnext": [
{
"address": "xxx.com",
"users": [
{
"id": "xxx-43bd-xxxx-bd60-xxx",
"alterId": 0,
"level": 0,
"security": "auto"
}
],
"port": 443
}
]
}
},
{
"tag": "direct",
"protocol": "freedom",
"settings": {
"domainStrategy": "UseIP",
"userLevel": 0
}
},
{
"tag": "block",
"protocol": "blackhole",
"settings": {
"response": {
"type": "none"
}
}
}
],
"dns": {},
"routing": {
"settings": {
"domainStrategy": "AsIs",
"rules": []
}
},
"transport": {}
}
- 主要言語
- Python
- スター
- 5
- フォーク
- 2
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
davideuler/programming-tips のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 35/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 45/100
-
build milvus on Macオープン
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
davideuler/programming-tips の issue をすべて見る
似ている issue
-
adr
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
kristofdegrave/homeassistant-smart-charging#1607 ·
メンテナーはふだん 1 日以内に返信
-
namespace operations
難易度 2/5 1〜3時間 初心者へのやさしさ 64/100
EclipseFdn/open-vsx.org#13665 ·
メンテナーはふだん 1 日以内に返信
-
doc good first issue help wanted
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
collective/icalendar#1865 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
canonical/opentelemetry-collector-operator#409 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
mozilla/addons-release-tests#1243 ·
メンテナーはふだん 1 日以内に返信