AnyBot/relay/Caddyfile

15 lines
508 B
Caddyfile
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 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
}
}