From e7362d27cdb81993dbbdb93bfe024df61fd28c2f Mon Sep 17 00:00:00 2001 From: Florian Sesser <florian@private.storage> Date: Mon, 18 Dec 2023 17:20:03 +0000 Subject: [PATCH] Pin system kernel to latest kernel that is supported by ZFS https://nixos.org/manual/nixos/stable/#sec-linux-zfs sounded like this is quite necessary, but on a second read I think we're fine since we are running the default (== latest available LTS) kernel anyway. --- morph/lib/storage.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/morph/lib/storage.nix b/morph/lib/storage.nix index 37efb8df..243f2249 100644 --- a/morph/lib/storage.nix +++ b/morph/lib/storage.nix @@ -1,6 +1,6 @@ # This contains all of the NixOS system configuration necessary to specify an # "storage"-type system. -{ lib, config, ...} : +{ lib, config, pkgs, ...} : let inherit (config.grid) privateKeyPath; in { @@ -49,6 +49,11 @@ in { services.private-storage.borgbackup.enable = lib.mkDefault true; + # We like to use ZFS on our storage servers. This ensures compatibility + # between the kernel and the required kernel modules. + # See https://nixos.org/manual/nixos/stable/#sec-linux-zfs + boot.kernelPackages = pkgs.zfs.latestCompatibleLinuxPackages; + # Turn on the Private Storage (Tahoe-LAFS) service. services.private-storage = { # Yep. Turn it on. -- GitLab