about summary refs log tree commit diff
path: root/machines/profpatsch/shiki.nix
diff options
context:
space:
mode:
authorProfpatsch <mail@profpatsch.de>2022-01-07 14:58:34 +0100
committerProfpatsch <mail@profpatsch.de>2022-01-07 15:01:34 +0100
commit51157ca8accfff40055801d310a929742ee77c34 (patch)
treeafbbb83499566b55befeaafcba32f86e509855c1 /machines/profpatsch/shiki.nix
parent630220b61484a4a79b7bcd5a4a079b031bf12e93 (diff)
machines/profpatsch/shiki: reference file systems by label not uuid
I want to mirror my disk to a 1:1 backup drive every so often, and
referencing disks by uuid means I can’t have a runnable system from a
different drive. Instead I use labels that can be shared between both
drives, so that the second drive is also bootable.
Diffstat (limited to 'machines/profpatsch/shiki.nix')
-rw-r--r--machines/profpatsch/shiki.nix14
1 files changed, 10 insertions, 4 deletions
diff --git a/machines/profpatsch/shiki.nix b/machines/profpatsch/shiki.nix
index bc506e3e..5a3c4f27 100644
--- a/machines/profpatsch/shiki.nix
+++ b/machines/profpatsch/shiki.nix
@@ -30,7 +30,7 @@ in {
     # Kernel
 
     boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "xhci_pci" "nvme" "usb_storage" "sd_mod" ];
-    boot.initrd.luks.devices.cryptroot.device = "/dev/disk/by-uuid/99922061-f883-4384-b1d9-a02d2ea88e59";
+    boot.initrd.luks.devices.cryptroot.device = "/dev/disk/by-label/root";
     boot.loader.systemd-boot.enable = true;
     boot.loader.grub.enable = false;
 
@@ -38,13 +38,15 @@ in {
     # Hardware
 
     fileSystems."/" = {
-      device = "/dev/disk/by-uuid/d88fb591-afa8-428f-bc24-5c096bcd762d";
+      device = "/dev/disk/by-label/nixos";
       fsType = "btrfs";
       options = [ "ssd" "subvol=/root" ];
     };
 
-    hardware.trackpoint = {
-      speed = 280;
+    fileSystems."/boot" = {
+      device = "/dev/disk/by-label/BOOT";
+      fsType = "vfat";
+      options = ["nofail"];
     };
 
     powerManagement = {
@@ -52,6 +54,10 @@ in {
       cpuFreqGovernor = "powersave";
     };
 
+    hardware.trackpoint = {
+      speed = 280;
+    };
+
     # hardware.pulseaudio = {
     #   enable = true;
     #   zeroconf.discovery.enable = true;