From 11b3dd292731d09c0d1d8fb73baca6bf9000c2b0 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 4 Jul 2025 09:22:50 +0200 Subject: [PATCH] Forgejo: Enable AWstats --- hosts/forgejo.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/hosts/forgejo.nix b/hosts/forgejo.nix index 831e4b5..6d9a789 100644 --- a/hosts/forgejo.nix +++ b/hosts/forgejo.nix @@ -135,6 +135,19 @@ in access_log /var/log/nginx/access.${domain}.log combined_realip; ''; + locations."/awstats/" = { + basicAuthFile = "/secrets/webstats_auth"; + }; + }; + }; + + services.awstats = { + enable = true; + updateAt = "hourly"; + configs."${domain}" = { + logFile = "/var/log/nginx/access.${domain}.log"; + domain = domain; + webService.enable = true; }; };