mermet: lock machine-id
authorJulien Moutinho <julm+sourcephile-nix@sourcephile.fr>
Mon, 9 Jan 2023 07:03:34 +0000 (08:03 +0100)
committerJulien Moutinho <julm+sourcephile-nix@sourcephile.fr>
Mon, 9 Jan 2023 07:03:34 +0000 (08:03 +0100)
hosts/losurdo/system.nix
hosts/mermet/machine-id.clear [new file with mode: 0644]
hosts/mermet/system.nix

index 3c5f553cf362c6fcd569ae13dc3e77c8d0264a6a..44eb3357be3570e5aed6aad52823a4b61bfe8f3c 100644 (file)
@@ -40,6 +40,7 @@
   # when reinstalling NixOS on a new drive.
   # Manually generated with : uuidgen | tr -d -
   environment.etc.machine-id.source = ./machine-id.clear;
+
   environment.systemPackages = with pkgs; [
     bluez
     cryptsetup
diff --git a/hosts/mermet/machine-id.clear b/hosts/mermet/machine-id.clear
new file mode 100644 (file)
index 0000000..f6e1a75
Binary files /dev/null and b/hosts/mermet/machine-id.clear differ
index 8d095e12c7d245b7e4e20b82598a226d8e275507..07b46564f53e966efcaf88cc8449842aebe06340 100644 (file)
   nix.gc.dates = "daily";
   nix.gc.options = "--delete-older-than 2d";
 
+  # Setting the machine-id avoids to reencrypt all credentials
+  # when reinstalling NixOS on a new drive.
+  # Manually generated with : uuidgen | tr -d -
+  environment.etc.machine-id.source = ./machine-id.clear;
+
   environment.systemPackages = with pkgs; [
     cryptsetup
     fio