disko: fix labels and config

This commit is contained in:
Kabbone 2023-12-20 14:02:15 +01:00
parent a965485be6
commit 1cd51d2034
Signed by: Kabbone
SSH Key Fingerprint: SHA256:A5zPB5I6u5V78V51c362BBdCwhDhfDUVbt7NfKdjWBY
2 changed files with 40 additions and 43 deletions

View File

@ -12,8 +12,8 @@
type = "EF00"; type = "EF00";
content = { content = {
type = "filesystem"; type = "filesystem";
name = "NIXBOOT";
format = "vfat"; format = "vfat";
extraArgs = [ "-n NIXBOOT" ];
mountpoint = "/boot"; mountpoint = "/boot";
mountOptions = [ mountOptions = [
"defaults" "defaults"
@ -24,41 +24,35 @@
size = "100%"; size = "100%";
content = { content = {
type = "btrfs"; type = "btrfs";
name = "NIXROOT"; extraArgs = [ "-f -L NIXROOT" ];
# disable settings.keyFile if you want to use interactive password entry subvolumes = {
#passwordFile = "/tmp/secret.key"; # Interactive "@" = {
settings = { mountpoint = "/";
allowDiscards = true; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
#keyFile = "/tmp/secret.key"; };
}; "@home" = {
content = { mountpoint = "/home";
type = "btrfs"; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
extraArgs = [ "-f" ]; };
subvolumes = { "@nix" = {
"@" = { mountpoint = "/nix";
mountpoint = "/"; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; };
}; "@snapshots" = {
"@home" = { mountpoint = "/mnt";
mountpoint = "/home"; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; };
}; "@srv" = {
"@srv" = { mountpoint = "/srv";
mountpoint = "/srv"; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; };
}; "@var" = {
"@nix" = { mountpoint = "/var";
mountpoint = "/nix"; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; };
}; "@swap" = {
"@var" = { mountpoint = "/swap";
mountpoint = "/var"; swap.swapfile.size = "8G";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
};
"@swap" = {
mountpoint = "/swap";
swap.swapfile.size = "8G";
};
}; };
}; };
}; };

View File

@ -12,8 +12,8 @@
type = "EF00"; type = "EF00";
content = { content = {
type = "filesystem"; type = "filesystem";
name = "NIXBOOT";
format = "vfat"; format = "vfat";
extraArgs = [ "-n NIXBOOT" ];
mountpoint = "/boot"; mountpoint = "/boot";
mountOptions = [ mountOptions = [
"defaults" "defaults"
@ -33,8 +33,7 @@
}; };
content = { content = {
type = "btrfs"; type = "btrfs";
name = "NIXROOT"; extraArgs = [ "-f -L NIXROOT" ];
extraArgs = [ "-f" ];
subvolumes = { subvolumes = {
"@" = { "@" = {
mountpoint = "/"; mountpoint = "/";
@ -44,14 +43,18 @@
mountpoint = "/home"; mountpoint = "/home";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
}; };
"@srv" = {
mountpoint = "/srv";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
};
"@nix" = { "@nix" = {
mountpoint = "/nix"; mountpoint = "/nix";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
}; };
"@snapshots" = {
mountpoint = "/mnt";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
};
"@srv" = {
mountpoint = "/srv";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];
};
"@var" = { "@var" = {
mountpoint = "/var"; mountpoint = "/var";
mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ]; mountOptions = [ "compress=zstd" "noatime" "ssd" "discard=async" ];