diff --git a/modules/services/web-servers/apache-httpd/default.nix b/modules/services/web-servers/apache-httpd/default.nix index 935a5e1be1a..ce3311a5f59 100644 --- a/modules/services/web-servers/apache-httpd/default.nix +++ b/modules/services/web-servers/apache-httpd/default.nix @@ -220,7 +220,7 @@ let ${if !isMainServer && mainCfg.logPerVirtualHost then '' ErrorLog ${mainCfg.logDir}/error_log-${cfg.hostName} - CustomLog ${mainCfg.logDir}/access_log-${cfg.hostName} ${mainCfg.logFormat} + CustomLog ${mainCfg.logDir}/access_log-${cfg.hostName} ${cfg.logFormat} '' else ""} ${robotsConf} @@ -447,14 +447,6 @@ in "; }; - logFormat = mkOption { - default = "common"; - example = "combined"; - description = " - Log format for Apache's log files. Possible values are: combined, common, referer, agent. - "; - }; - stateDir = mkOption { default = "/var/run/httpd"; description = " diff --git a/modules/services/web-servers/apache-httpd/per-server-options.nix b/modules/services/web-servers/apache-httpd/per-server-options.nix index 00b82550bbe..a5227bae2d4 100644 --- a/modules/services/web-servers/apache-httpd/per-server-options.nix +++ b/modules/services/web-servers/apache-httpd/per-server-options.nix @@ -135,4 +135,12 @@ "; }; + logFormat = mkOption { + default = "common"; + example = "combined"; + description = " + Log format for Apache's log files. Possible values are: combined, common, referer, agent. + "; + }; + }