nixos-config/system/zfs.nix
2024-05-12 15:05:34 +02:00

27 lines
592 B
Nix

{ config, my, pkgs, ... }:
{
boot.kernelPackages = config.boot.zfs.package.latestCompatibleLinuxPackages;
boot.supportedFilesystems = [ "zfs" ];
boot.initrd.supportedFilesystems = [ "zfs" ];
environment.systemPackages = with pkgs; [ zfs ];
services.zfs = {
autoScrub.enable = true;
autoSnapshot = {
enable = true;
frequent = 4;
hourly = 24;
daily = 14;
weekly = 8;
monthly = 12;
};
trim.enable = true;
zed.settings = {
ZED_SLACK_WEBHOOK_URL = my.notifications.zfs-bot.url;
ZED_NOTIFY_VERBOSE = 1;
};
};
}