From 692da961d84ef3434b7949b59bc6cff8e147bf3a Mon Sep 17 00:00:00 2001 From: clerie Date: Sun, 18 Feb 2024 14:40:26 +0100 Subject: [PATCH 1/4] hosts/web-2: Remove znc --- hosts/web-2/configuration.nix | 1 - hosts/web-2/znc.nix | 29 ----------------------------- 2 files changed, 30 deletions(-) delete mode 100644 hosts/web-2/znc.nix diff --git a/hosts/web-2/configuration.nix b/hosts/web-2/configuration.nix index 2bf471f..76b8817 100644 --- a/hosts/web-2/configuration.nix +++ b/hosts/web-2/configuration.nix @@ -26,7 +26,6 @@ ./tap.nix ./uptimestatus.nix ./wetter.nix - ./znc.nix ]; boot.loader.grub.enable = true; diff --git a/hosts/web-2/znc.nix b/hosts/web-2/znc.nix deleted file mode 100644 index fa6cb09..0000000 --- a/hosts/web-2/znc.nix +++ /dev/null @@ -1,29 +0,0 @@ -{ ... }: - -{ - services.znc = { - enable = true; - mutable = true; - dataDir = "/var/lib/znc"; - configFile = "/var/lib/znc/configs/znc.conf"; - }; - - services.nginx.virtualHosts = { - "znc.clerie.de" = { - enableACME = true; - forceSSL = true; - locations."/" = { - proxyPass = "http://127.0.0.1:1313"; - }; - }; - }; - - clerie.nginx-port-forward = { - enable = true; - tcpPorts."6697" = { - host = "127.0.0.1"; - port = 1311; - certName = "znc.clerie.de"; - }; - }; -} From 15670ff5412ba0ea91c13a4e5444a925fd208804 Mon Sep 17 00:00:00 2001 From: clerie Date: Sun, 18 Feb 2024 14:58:45 +0100 Subject: [PATCH 2/4] hosts/storage-2: Replace prepare script with tmpfiles --- hosts/storage-2/mixcloud.nix | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/hosts/storage-2/mixcloud.nix b/hosts/storage-2/mixcloud.nix index a8a0ed0..7b81c0d 100644 --- a/hosts/storage-2/mixcloud.nix +++ b/hosts/storage-2/mixcloud.nix @@ -82,17 +82,10 @@ in { }; users.groups.data-mixcloud = {}; - systemd.services = { - "youtube-dl-prepare" = { - serviceConfig = { - Type = "oneshot"; - RemainAfterExit = "true"; - }; - script = '' - mkdir -p /data/mixcloud - chown -R data-mixcloud:data-mixcloud /data/mixcloud - ''; - }; - } // (mapAttrs' generateYoutubedlMixcloudUnits mixcloudSources); + systemd.tmpfiles.rules = [ + "d /data/mixcloud - data-mixcloud data-mixcloud - -" + ]; + + systemd.services = (mapAttrs' generateYoutubedlMixcloudUnits mixcloudSources); systemd.timers = (mapAttrs' generateYoutubedlMixcloudTimers mixcloudSources); } From 1efe5aebca770acfe5b40050c61f2959291e7d0b Mon Sep 17 00:00:00 2001 From: clerie Date: Sun, 18 Feb 2024 15:07:17 +0100 Subject: [PATCH 3/4] flake.lock: Update nixpkgs --- flake.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/flake.lock b/flake.lock index 9d05173..ccc4e02 100644 --- a/flake.lock +++ b/flake.lock @@ -212,11 +212,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1701253981, - "narHash": "sha256-ztaDIyZ7HrTAfEEUt9AtTDNoCYxUdSd6NrRHaYOIxtk=", + "lastModified": 1708118438, + "narHash": "sha256-kk9/0nuVgA220FcqH/D2xaN6uGyHp/zoxPNUmPCMmEE=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "e92039b55bcd58469325ded85d4f58dd5a4eaf58", + "rev": "5863c27340ba4de8f83e7e3c023b9599c3cb3c80", "type": "github" }, "original": { From a84ae9372ed6e75f2803c9329e49435f08eed9cd Mon Sep 17 00:00:00 2001 From: clerie Date: Sun, 18 Feb 2024 16:47:54 +0100 Subject: [PATCH 4/4] hosts/minecraft-2,hosts/storage-2: Enable auto update --- hosts/minecraft-2/configuration.nix | 5 +++++ hosts/storage-2/configuration.nix | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/hosts/minecraft-2/configuration.nix b/hosts/minecraft-2/configuration.nix index 805e088..3a893b0 100644 --- a/hosts/minecraft-2/configuration.nix +++ b/hosts/minecraft-2/configuration.nix @@ -62,6 +62,11 @@ in { }; }; + clerie.nixfiles.system-auto-upgrade = { + allowReboot = true; + autoUpgrade = true; + }; + clerie.monitoring = { enable = true; id = "202"; diff --git a/hosts/storage-2/configuration.nix b/hosts/storage-2/configuration.nix index de08aad..4aaea5a 100644 --- a/hosts/storage-2/configuration.nix +++ b/hosts/storage-2/configuration.nix @@ -26,6 +26,11 @@ networking.firewall.allowedTCPPorts = [ 80 443 ]; + clerie.nixfiles.system-auto-upgrade = { + allowReboot = true; + autoUpgrade = true; + }; + clerie.monitoring = { enable = true; id = "209";