From df4e229dddff0a69e9d26054a17a41ee32deb7dd Mon Sep 17 00:00:00 2001 From: Aaron Honeycutt Date: Mon, 28 Jul 2025 06:31:54 -0600 Subject: [PATCH] Edit default.nix --- homelab/ahoneybun-net/default.nix | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/homelab/ahoneybun-net/default.nix b/homelab/ahoneybun-net/default.nix index eb8393b..86eb87e 100644 --- a/homelab/ahoneybun-net/default.nix +++ b/homelab/ahoneybun-net/default.nix @@ -1,10 +1,27 @@ { config, pkgs, lib, ... }: { + systemd.user.services."website-zola-build" = { + enable = true; + description = "rebuild zola website"; + serviceConfig = { + ExecStart = "/run/current-system/sw/bin/zola -r /mnt/DATA/Website/ahoneybun-net build"; + }; + wantedBy = [ "default.target" ]; + }; + + systemd.user.timers."website-zola-build" = { + wantedBy = [ "timers.target" ]; + timerConfig = { + OnBootSec = "2h"; + OnUnitActiveSec = "7h"; + }; + }; + services.nginx = { enable = true; virtualHosts."ahoneybun.net" = { - root = "/mnt/DATA/Website/ahoneybun.net/public"; + root = "/mnt/DATA/Website/ahoneybun-net/public"; locations."/" = { extraConfig = '' default_type text/html;