added option to specify logformat to apache httpd, defaults to common (like it was until now)

svn path=/nixos/trunk/; revision=17923
This commit is contained in:
Rob Vermaas 2009-10-22 14:36:54 +00:00
parent 1e1ae9cd1e
commit 9e80ca48cb

View File

@ -121,7 +121,7 @@ let
LogFormat "%{Referer}i -> %U" referer LogFormat "%{Referer}i -> %U" referer
LogFormat "%{User-agent}i" agent LogFormat "%{User-agent}i" agent
CustomLog ${mainCfg.logDir}/access_log common CustomLog ${mainCfg.logDir}/access_log ${mainCfg.logFormat}
''; '';
@ -218,7 +218,7 @@ let
${if !isMainServer && mainCfg.logPerVirtualHost then '' ${if !isMainServer && mainCfg.logPerVirtualHost then ''
ErrorLog ${mainCfg.logDir}/error_log-${cfg.hostName} ErrorLog ${mainCfg.logDir}/error_log-${cfg.hostName}
CustomLog ${mainCfg.logDir}/access_log-${cfg.hostName} common CustomLog ${mainCfg.logDir}/access_log-${cfg.hostName} ${mainCfg.logFormat}
'' else ""} '' else ""}
${robotsConf} ${robotsConf}
@ -429,6 +429,13 @@ in
"; ";
}; };
logFormat = mkOption {
default = "common";
description = "
Log format for Apache's log files.
";
};
stateDir = mkOption { stateDir = mkOption {
default = "/var/run/httpd"; default = "/var/run/httpd";
description = " description = "
@ -456,6 +463,7 @@ in
''; '';
}; };
subservices = { subservices = {
# !!! remove this # !!! remove this