Fixed caddy reverse proxy for gRPC (#82)

* Fixed caddy reverse proxy for gRPC

* Fixed tab/space
This commit is contained in:
Hirbod Behnam 2022-10-20 16:24:41 +03:30 committed by GitHub
parent d959d222e7
commit e2147abd96
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 22 additions and 14 deletions

View file

@ -1,9 +1,13 @@
example.com { example.com {
@grpc { @grpc {
protocol grpc protocol grpc
path # 填写 /你的 ServiceName/* path # 填写 /你的 ServiceName/*
} }
reverse_proxy @grpc unix//dev/shm/Xray-Trojan-gRPC.socket reverse_proxy @grpc unix//dev/shm/Xray-Trojan-gRPC.socket {
root * /var/www transport http {
file_server versions h2c
}
}
root * /var/www
file_server
} }

View file

@ -1,9 +1,13 @@
xx.com { xx.com {
@grpc { @grpc {
protocol grpc protocol grpc
path # 填写 /你的 ServiceName/* path # 填写 /你的 ServiceName/*
} }
reverse_proxy @grpc unix//dev/shm/Xray-VLESS-gRPC.socket reverse_proxy @grpc unix//dev/shm/Xray-Trojan-gRPC.socket {
root * /var/www transport http {
file_server versions h2c
}
}
root * /var/www
file_server
} }