diff options
| author | Seth Flynn <[email protected]> | 2025-02-05 10:19:41 -0500 |
|---|---|---|
| committer | Seth Flynn <[email protected]> | 2025-02-05 10:19:41 -0500 |
| commit | 085fb5b9c9347aae2cf502a8e0179c0d731e9e68 (patch) | |
| tree | 28aadd3fb1b5a911d8d58597c20be21c312e4f55 /systems/glados | |
| parent | ba858dddd889e2e12c0da13e8bd3aaa718d35334 (diff) | |
glados: allocate swapfile
Diffstat (limited to 'systems/glados')
| -rw-r--r-- | systems/glados/default.nix | 11 | ||||
| -rw-r--r-- | systems/glados/hardware-configuration.nix | 9 |
2 files changed, 20 insertions, 0 deletions
diff --git a/systems/glados/default.nix b/systems/glados/default.nix index cf1ea9f..a8e063c 100644 --- a/systems/glados/default.nix +++ b/systems/glados/default.nix @@ -55,6 +55,17 @@ fwupd.enable = true; }; + swapDevices = [ + { + # WARN: Don't set size! + # + # We're on btrfs and the NixOS module won't handle it properly. + # Make it 4GB or so manually with + # `btrfs filesystem mkswapfile --size 4g --uuid clear /swap/swapfile` in it's own subvol + device = "/swap/swapfile"; + } + ]; + system.stateVersion = "23.11"; traits = { diff --git a/systems/glados/hardware-configuration.nix b/systems/glados/hardware-configuration.nix index bd5f220..413471f 100644 --- a/systems/glados/hardware-configuration.nix +++ b/systems/glados/hardware-configuration.nix @@ -74,6 +74,15 @@ ]; }; + "/swap" = { + device = "/dev/mapper/cryptroot"; + fsType = "btrfs"; + options = [ + "subvol=swap" + "noatime" + ]; + }; + "/boot" = { device = "/dev/disk/by-uuid/B95B-9412"; fsType = "vfat"; |
