1. Caddy version (caddy version
):
2. How I run Caddy:
a. System environment:
b. Command:
c. Service/unit/compose file:
d. My complete Caddyfile or JSON config:
3. The problem I’m having:
In the documentation for Caddyfile configuration, I have not discovered how to tell the default values unless it explicitly says “Default:”, but not all directives do this. How can tell what the default value is?
4. Error messages and/or full log output:
5. What I already tried:
6. Links to relevant resources:
agrajag
(Todd Grayson)
November 24, 2021, 12:08am
2
What I’ve found is that there really are not defaults beyond the items documented in the directives section of the caddyfile documentation, and some of them are based on parent configuration directives being set, that have default values under them.
Is there a specific configuration pattern you are trying to understand?
1 Like
Please fill out the help topic template, we can’t really help with vague questions like this.
Not at this time. But, for example, what is the default for read_buffer ? http_transport
It uses the default from the Go stdlib, i.e. 4KiB
: http package - net/http - pkg.go.dev
1 Like
So if a default is not given in the Caddy docs, then we refer to the Go docs?
1 Like
Basically. It’s an oversight though, and you’re the first to have pointed it out. I’ll fix the docs soon.
2 Likes
Made a PR for the docs:
caddyserver:master
← caddyserver:proxy-transport-defaults
opened 03:11AM - 24 Nov 21 UTC
Pairs with https://github.com/caddyserver/caddy/pull/4436.
I could split thes… e changes in two, some changes should only land in 2.5.0, but others are pure documentation that could be pushed live now. But 🤷♂️ I think it's fine for these to wait until 2.5.0, what's another month or whatever? 😅
Keep in mind that not all of those timeout values are correct as of v2.4.6, because some of them are being adjusted for v2.5.0 (specifically dial_timeout
). See reverseproxy: Adjust defaults, document defaults by francislavoie · Pull Request #4436 · caddyserver/caddy · GitHub
1 Like
system
(system)
Closed
December 23, 2021, 11:17pm
9
This topic was automatically closed after 30 days. New replies are no longer allowed.