aboutsummaryrefslogtreecommitdiff
path: root/modules/profiles/zfs/default.nix
blob: 83444507863343688bd6761954194a2bd94a99cc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{ lib, pkgs, ... }:
{
  boot = {
    zfs.forceImportRoot = false;
    supportedFilesystems.zfs = lib.mkForce true;
  };

  services.zfs = {
    autoScrub.enable = true;
    zed = {
      enableMail = false;
      settings = {
        ZED_DEBUG_LOG = "/tmp/zed.debug.log";
        ZED_EMAIL_ADDR = [ "root" ];
        ZED_EMAIL_PROG = "/run/current-system/sw/bin/pushover";
        ZED_EMAIL_OPTS = "-t '@SUBJECT@'";
        ZED_NOTIFY_INTERVAL_SECS = 3600;
        ZED_NOTIFY_VERBOSE = true;
        ZED_USE_ENCLOSURE_LEDS = true;
        ZED_SCRUB_AFTER_RESILVER = true;
      };
    };
  };

  environment.systemPackages = with pkgs; [
    zfs
  ];
}