Changes for lambda, with tmpfs root
This commit is contained in:
@@ -23,14 +23,13 @@ in {
|
||||
kernelModules = [ ];
|
||||
};
|
||||
|
||||
kernelModules = [ "kvm-amd" ];
|
||||
kernelPackages = pkgs.linuxPackages.zfs;
|
||||
kernelModules = [ "kvm-intel" ];
|
||||
supportedFilesystems = [ "zfs" ];
|
||||
|
||||
loader.grub = {
|
||||
enable = true;
|
||||
version = 2;
|
||||
device = "/dev/disk/by-label/lambda-root";
|
||||
device = "/dev/disk/by-id/wwn-0x600508b1001cecf6b880f591f9b18b29";
|
||||
};
|
||||
};
|
||||
|
||||
@@ -38,11 +37,13 @@ in {
|
||||
"/boot" = {
|
||||
device = "/dev/disk/by-label/lambda-boot";
|
||||
fsType = "ext4";
|
||||
options = [ "noexec" ];
|
||||
};
|
||||
|
||||
"/" = {
|
||||
device = "lambda/transient/root";
|
||||
fsType = "zfs";
|
||||
device = "none";
|
||||
fsType = "tmpfs";
|
||||
options = [ "noexec" ];
|
||||
};
|
||||
|
||||
"/nix" = {
|
||||
@@ -54,29 +55,20 @@ in {
|
||||
device = "lambda/transient/logs";
|
||||
fsType = "zfs";
|
||||
neededForBoot = true;
|
||||
};
|
||||
|
||||
"/home" = {
|
||||
device = "lambda/persistent/home";
|
||||
fsType = "zfs";
|
||||
options = [ "noexec" ];
|
||||
};
|
||||
|
||||
"/state" = {
|
||||
device = "lambda/persistent/state";
|
||||
fsType = "zfs";
|
||||
options = [ "noexec" ];
|
||||
};
|
||||
};
|
||||
|
||||
boot.initrd.postDeviceCommands = lib.mkAfter ''
|
||||
${pkgs.zfs}/bin/zfs rollback -r lambda/transient/root@blank
|
||||
'';
|
||||
|
||||
swapDevices = [{ device = "/dev/disk/by-label/lambda-swap"; }];
|
||||
|
||||
nix.maxJobs = lib.mkDefault 12;
|
||||
|
||||
hardware.bluetooth.enable = false;
|
||||
|
||||
networking = {
|
||||
hostId = substring 0 8 (fileContents /etc/machine-id);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user