Update Caddyfile

This commit is contained in:
EIKULG 2021-03-19 12:08:16 +08:00 committed by GitHub
parent 45af5cad23
commit 561ce4963e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,22 +4,16 @@ xx.com {
header Connection *Upgrade* header Connection *Upgrade*
header Upgrade websocket header Upgrade websocket
} }
@grpc { @grpc protocol grpc
protocol grpc reverse_proxy @ws http://127.0.0.1:2001
} reverse_proxy @grpc h2c://127.0.0.1:2002 {
reverse_proxy @ws {
to http://127.0.0.1:2001
}
reverse_proxy @grpc {
to h2c://127.0.0.1:2002
transport http { transport http {
versions h2c 2 versions h2c
} }
} }
reverse_proxy /h2 { reverse_proxy /h2 h2c://127.0.0.1:2003 {
to h2c://127.0.0.1:2003
transport http { transport http {
versions h2c 2 versions h2c
} }
} }
root * /var/www root * /var/www