diff options
Diffstat (limited to 'hosts/surtr/default.nix')
-rw-r--r-- | hosts/surtr/default.nix | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/hosts/surtr/default.nix b/hosts/surtr/default.nix index b8a639d5..9d3101c0 100644 --- a/hosts/surtr/default.nix +++ b/hosts/surtr/default.nix | |||
@@ -7,6 +7,7 @@ with lib; | |||
7 | tmpfs-root qemu-guest openssh rebuild-machines zfs | 7 | tmpfs-root qemu-guest openssh rebuild-machines zfs |
8 | ./zfs.nix ./dns ./tls ./http ./bifrost ./matrix ./postgresql | 8 | ./zfs.nix ./dns ./tls ./http ./bifrost ./matrix ./postgresql |
9 | ./prometheus ./email ./vpn ./borg.nix ./etebase ./immich.nix | 9 | ./prometheus ./email ./vpn ./borg.nix ./etebase ./immich.nix |
10 | ./paperless.nix ./hledger.nix ./audiobookshelf.nix ./kimai.nix | ||
10 | ]; | 11 | ]; |
11 | 12 | ||
12 | config = { | 13 | config = { |
@@ -14,9 +15,6 @@ with lib; | |||
14 | system = "x86_64-linux"; | 15 | system = "x86_64-linux"; |
15 | }; | 16 | }; |
16 | 17 | ||
17 | networking.hostId = "a64cf4d7"; | ||
18 | environment.etc."machine-id".text = "a64cf4d793ab0a0ed3892ead609fc0bc"; | ||
19 | |||
20 | boot = { | 18 | boot = { |
21 | loader.grub = { | 19 | loader.grub = { |
22 | enable = true; | 20 | enable = true; |
@@ -30,6 +28,15 @@ with lib; | |||
30 | zfs.devNodes = "/dev"; # /dev/vda2 does not show up in /dev/disk/by-id | 28 | zfs.devNodes = "/dev"; # /dev/vda2 does not show up in /dev/disk/by-id |
31 | 29 | ||
32 | kernelModules = ["ptp_kvm"]; | 30 | kernelModules = ["ptp_kvm"]; |
31 | kernelPatches = [ | ||
32 | { name = "zswap-default"; | ||
33 | patch = null; | ||
34 | extraStructuredConfig = with lib.kernel; { | ||
35 | ZSWAP_DEFAULT_ON = yes; | ||
36 | ZSWAP_SHRINKER_DEFAULT_ON = yes; | ||
37 | }; | ||
38 | } | ||
39 | ]; | ||
33 | }; | 40 | }; |
34 | 41 | ||
35 | fileSystems = { | 42 | fileSystems = { |
@@ -38,6 +45,9 @@ with lib; | |||
38 | fsType = "vfat"; | 45 | fsType = "vfat"; |
39 | }; | 46 | }; |
40 | }; | 47 | }; |
48 | swapDevices = [ | ||
49 | { label = "swap"; } | ||
50 | ]; | ||
41 | 51 | ||
42 | networking = { | 52 | networking = { |
43 | hostName = "surtr"; | 53 | hostName = "surtr"; |
@@ -163,11 +173,6 @@ with lib; | |||
163 | stateful = true; | 173 | stateful = true; |
164 | }; | 174 | }; |
165 | 175 | ||
166 | zramSwap = { | ||
167 | enable = true; | ||
168 | algorithm = "zstd"; | ||
169 | }; | ||
170 | |||
171 | systemd.sysusers.enable = false; | 176 | systemd.sysusers.enable = false; |
172 | system.etc.overlay.mutable = true; | 177 | system.etc.overlay.mutable = true; |
173 | boot.enableContainers = true; | 178 | boot.enableContainers = true; |