summaryrefslogtreecommitdiff
path: root/hosts/surtr/zfs.nix
diff options
context:
space:
mode:
Diffstat (limited to 'hosts/surtr/zfs.nix')
-rw-r--r--hosts/surtr/zfs.nix24
1 files changed, 19 insertions, 5 deletions
diff --git a/hosts/surtr/zfs.nix b/hosts/surtr/zfs.nix
index 3a69fd96..736d5cc9 100644
--- a/hosts/surtr/zfs.nix
+++ b/hosts/surtr/zfs.nix
@@ -35,11 +35,25 @@
35 fsType = "zfs"; 35 fsType = "zfs";
36 }; 36 };
37 37
38 "/srv" = 38 # "/srv" =
39 { device = "surtr/safe/srv"; 39 # { device = "surtr/safe/srv";
40 fsType = "zfs"; 40 # fsType = "zfs";
41 options = [ "zfsutil" ]; 41 # options = [ "zfsutil" ];
42 }; 42 # };
43 };
44
45 boot.postBootCommands = ''
46 echo "=== STARTING ZPOOL IMPORT ==="
47 ${pkgs.zfs}/bin/zpool import -a -N -d /dev
48 ${pkgs.zfs}/bin/zpool status
49 ${pkgs.zfs}/bin/zfs mount -a
50 echo "=== ZPOOL IMPORT COMPLETE ==="
51 '';
52
53 system.activationScripts = {
54 zfsMount.text = ''
55 ${pkgs.zfs}/bin/zfs mount -a
56 '';
43 }; 57 };
44 58
45 services.zfssnap.enable = true; 59 services.zfssnap.enable = true;