15 lines
508 B
Caddyfile
15 lines
508 B
Caddyfile
# Caddy gets and renews the HTTPS certificate by itself.
|
||
# Replace anybot.example.com with your own domain (its DNS must point to this server).
|
||
anybot.example.com {
|
||
encode gzip
|
||
reverse_proxy relay:8080 {
|
||
# The phone's "anything new?" request waits up to 35 s. Each AnyBot also keeps one
|
||
# WebSocket open here (pinged every 15–20 s, so it never sits idle for 60 s).
|
||
transport http {
|
||
read_timeout 60s
|
||
}
|
||
# Reloading this file doesn't cut those connections at once.
|
||
stream_close_delay 5m
|
||
}
|
||
}
|