nixos/caddy: Make virtualHosts' logFormat optional (#392390)
This commit is contained in:
commit
9e087896d6
@ -30,9 +30,11 @@ let
|
||||
${optionalString (
|
||||
hostOpts.useACMEHost != null
|
||||
) "tls ${sslCertDir}/cert.pem ${sslCertDir}/key.pem"}
|
||||
log {
|
||||
${hostOpts.logFormat}
|
||||
}
|
||||
${optionalString (hostOpts.logFormat != null) ''
|
||||
log {
|
||||
${hostOpts.logFormat}
|
||||
}
|
||||
''}
|
||||
|
||||
${hostOpts.extraConfig}
|
||||
}
|
||||
|
||||
@ -56,7 +56,7 @@ in
|
||||
};
|
||||
|
||||
logFormat = mkOption {
|
||||
type = types.lines;
|
||||
type = types.nullOr types.lines;
|
||||
default = ''
|
||||
output file ${cfg.logDir}/access-${lib.replaceStrings [ "/" " " ] [ "_" "_" ] config.hostName}.log
|
||||
'';
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user