finished modifying luks-lvm

This commit is contained in:
Steven 2023-03-25 20:59:43 -04:00
parent b6d1ba3a24
commit 086a5dbc08
2 changed files with 20 additions and 13 deletions

View file

@ -32,7 +32,9 @@
};
};
};
disko.devices = pkgs.callPackage ../disko/luks-lvm.nix {
disks = [ "/dev/nvme" ]; # replace this with your disk name i.e. /dev/nvme0n1
};
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction

View file

@ -1,6 +1,6 @@
{ disks ? [ "/dev/nvme0n1" ], ... }: {
disk = {
nvme0n1 = {
disk-0 = {
type = "disk";
device = builtins.elemAt disks 0;
content = {
@ -9,6 +9,7 @@
partitions = [
{
type = "partition";
extraArgs = "--label nixboot01";
name = "ESP";
start = "1MiB";
end = "100MiB";
@ -22,19 +23,21 @@
];
};
}
# {
# name = "swap";
# type = "partition";
# start = "101MiB";
# end = "40960MiB";
# part-type = "primary";
# content = {
# type = "swap";
# randomEncryption = true;
# };
# }
{
name = "swap";
type = "partition";
extraArgs = "--label nixswap01";
start = "101MiB";
end = "40960MiB";
part-type = "primary";
content = {
type = "swap";
randomEncryption = true;
};
}
{
type = "partition";
extraArgs = "--label nixpv01";
name = "luks";
start = "40960MiB";
end = "100%";
@ -59,6 +62,7 @@
lvs = {
root = {
type = "lvm_lv";
extraArgs = "--label nixroot";
size = "128G";
content = {
type = "filesystem";
@ -71,6 +75,7 @@
};
home = {
type = "lvm_lv";
extraArgs = "--label nixhome";
size = "25G";
content = {
type = "filesystem";