services.caddy.adapter
Name of the config adapter to use. See https://caddyserver.com/docs/config-adapters for the full list.
If null is specified, the --adapter argument is omitted when
starting or restarting Caddy. Notably, this allows specification of a
configuration file in Caddy's native JSON format, as long as the
filename does not start with Caddyfile (in which case the caddyfile
adapter is implicitly enabled). See
https://caddyserver.com/docs/command-line#caddy-run for details.
Any value other than null or caddyfile is only valid when providing
your own configFile.
- Type
null or string- Default
if ((cfg.configFile != configFile) || (baseNameOf cfg.configFile) == "Caddyfile") then "caddyfile" else null- Example
nginx- Declared
- <nixpkgs/nixos/modules/services/web-servers/caddy/default.nix>