config

NixOS config
Log | Files | Refs | README | LICENSE

commit 44fc5f979248e6db7b8c8a7a2f0b739f43c8cd1b (tree)
parent 7b13770c947420e6c85d91481f6bf777e3e3634f
Author: Motiejus Jakštys <motiejus@jakstys.lt>
Date:   Sun, 30 Mar 2025 19:26:48 +0000

some testing

Diffstat:
Mhosts/mtworx/configuration.nix | 20++++++++++++++++++++
Mmodules/services/timelapse-r11/default.nix | 2+-
2 files changed, 21 insertions(+), 1 deletion(-)

diff --git a/hosts/mtworx/configuration.nix b/hosts/mtworx/configuration.nix @@ -1,4 +1,5 @@ { + lib, config, pkgs, myData, @@ -6,6 +7,13 @@ }: let nvme = "/dev/disk/by-id/nvme-WD_PC_SN810_SDCQNRY-1T00-1201_23234W800017"; + timelapseScript = pkgs.writeShellApplication { + name = "timelapse-test"; + text = '' + date >> /tmp/timelapse-test + sleep 5m + ''; + }; in { imports = [ @@ -53,6 +61,18 @@ in }; }; + systemd = { + timers.timelapse-test = { + timerConfig.onCalendar = "*-*-* *:*:30"; + }; + services.timelapse-test.serviceConfig = { + ExecStart = lib.getExe timelapseScript; + StateDirectory = "timelapse-test"; + Type = "simple"; + RuntimeMaxSec = "30s"; + }; + }; + swapDevices = [ { device = "${nvme}-part2"; diff --git a/modules/services/timelapse-r11/default.nix b/modules/services/timelapse-r11/default.nix @@ -61,7 +61,7 @@ in StateDirectory = "timelapse-r11"; DynamicUser = true; Type = "simple"; - RuntimeMaxSecs = "45s"; + RuntimeMaxSec = "45s"; }; };