Added gRPC example (#66)

This commit is contained in:
Hirbod Behnam 2021-04-02 15:16:27 +04:30 committed by GitHub
parent 04017a8c67
commit c0d34dba35
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 114 additions and 0 deletions

View File

@ -0,0 +1,57 @@
{
"log": {
"loglevel": "warning"
},
"inbounds": [
{
"listen": "127.0.0.1",
"port": "1080",
"protocol": "socks",
"settings": {
"auth": "noauth",
"udp": true,
"ip": "127.0.0.1"
}
},
{
"listen": "127.0.0.1",
"port": "1081",
"protocol": "http"
}
],
"outbounds": [
{
"protocol": "vless",
"settings": {
"vnext": [
{
"address": "1.2.3.4",
"port": 443,
"users": [
{
"id": "",
"encryption": "none",
"level": 0
}
]
}
]
},
"streamSettings": {
"network": "gun",
"security": "tls",
"tlsSettings": {
"serverName": "your.domain.com",
"allowInsecure": false,
"alpn": [
"h2"
],
"disableSessionResumption": true
},
"grpcSettings": {
"serviceName": "GunService"
}
}
}
]
}

View File

@ -0,0 +1,57 @@
{
"log": {
"loglevel": "warning"
},
"inbounds": [
{
"listen": "0.0.0.0",
"port": 443,
"protocol": "vless",
"settings": {
"clients": [
{
"id": "",
"level": 0,
"email": "love@v2fly.org"
}
],
"decryption": "none",
"fallbacks": [
{
"dest": 8001
},
{
"alpn": "h2",
"dest": 8002
}
]
},
"streamSettings": {
"network": "gun",
"security": "tls",
"tlsSettings": {
"serverName": "your.domain.com",
"alpn": [
"h2",
"http/1.1"
],
"certificates": [
{
"certificateFile": "/path/to/fullchain.crt",
"keyFile": "/path/to/private.key"
}
],
"grpcSettings": {
"serviceName": "GunService"
}
}
}
}
],
"outbounds": [
{
"protocol": "freedom",
"tag": "direct"
}
]
}