mirror of
https://git.pvv.ntnu.no/Drift/pvv-nixos-config.git
synced 2026-05-26 00:01:12 +02:00
WIP: temmie/userweb: add log processor for apache
This commit is contained in:
@@ -11,6 +11,8 @@ let
|
||||
upload_max_filesize = "40M";
|
||||
});
|
||||
|
||||
apache-log-processor = pkgs.callPackage ./apache-log-processor { };
|
||||
|
||||
# https://nixos.org/manual/nixpkgs/stable/#ssec-php-user-guide-installing-with-extensions
|
||||
phpEnv = pkgs.php.buildEnv {
|
||||
extensions = { all, ... }: with all; [
|
||||
@@ -193,10 +195,11 @@ in
|
||||
}
|
||||
];
|
||||
|
||||
logPerVirtualHost = false;
|
||||
|
||||
extraConfig = ''
|
||||
TraceEnable on
|
||||
LogLevel warn rewrite:trace3
|
||||
ScriptLog ${cfg.logDir}/cgi.log
|
||||
'';
|
||||
|
||||
virtualHosts."temmie.pvv.ntnu.no" = {
|
||||
@@ -208,6 +211,11 @@ in
|
||||
];
|
||||
|
||||
extraConfig = ''
|
||||
CustomLog "${cfg.logDir}/access.log" combined
|
||||
CustomLog "|${lib.getExe apache-log-processor} access" combined
|
||||
ErrorLog "|${lib.getExe apache-log-processor} error"
|
||||
ScriptLog "${cfg.logDir}/cgi.log"
|
||||
|
||||
UserDir ${lib.concatMapStringsSep " " (l: "/home/pvv/${l}/*/web-docs") homeLetters}
|
||||
UserDir disabled root
|
||||
AddHandler cgi-script .cgi
|
||||
|
||||
Reference in New Issue
Block a user