This commit is contained in:
DuN0z 2025-10-09 17:46:15 +02:00
parent fd5f22ae65
commit 845c3373ba
9 changed files with 65 additions and 55 deletions

View file

@ -1,4 +1,7 @@
{pkgs, ...}: {
{pkgs, ...}:
let
imports = ../../config/globals.nix ;
in {
environment.systemPackages = with pkgs; [
goaccess
];
@ -7,7 +10,7 @@
systemd.services.goaccess-report = {
description = "Generate GoAccess HTML report";
serviceConfig = {
ExecStart = "${pkgs.goaccess}/bin/goaccess /var/log/caddy/access-levr.porzh.me.log --log-format=CADDY -o /var/www/goaccess/index.html";
ExecStart = "${pkgs.goaccess}/bin/goaccess /var/log/caddy/access-${globals.services.levr.url}.log --log-format=CADDY -o ${globals.services.goaccess.home}/index.html";
};
};
@ -22,9 +25,9 @@
};
services.caddy = {
virtualHosts = {
"koum.porzh.me" = {
globals.services.goaccess.url = {
extraConfig = ''
root * /var/www/goaccess
root * ${globals.services.goaccess.home}
file_server browse
try_files {path} {path}/ /index.html