Skip to content

Commit 017759b

Browse files
committed
Add support for gRPC protocol
v2ray-core default gRPC protocolName is "gun" Signed-off-by: Teddysun <i@teddysun.com>
1 parent 2ada385 commit 017759b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

main.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,11 @@ func generateConfig() (*core.Config, error) {
152152
return nil, newError("unsupported mode:", *mode)
153153
}
154154

155+
// hack v2ray-core grpc protocolName
156+
if *mode == "grpc" {
157+
*mode = "gun"
158+
}
159+
155160
streamConfig := internet.StreamConfig{
156161
ProtocolName: *mode,
157162
TransportSettings: []*internet.TransportConfig{{

0 commit comments

Comments
 (0)