Infini-STICK: resetup with disko

This commit is contained in:
Infinidoge 2024-11-23 04:06:04 -05:00
parent f27d02d161
commit 43087082c4
Signed by: Infinidoge
SSH key fingerprint: SHA256:oAMyvotlNFraMmZmr+p6AxnNfW/GioTs1pOn3V4tQ7A
10 changed files with 32 additions and 425 deletions

View file

@ -0,0 +1,28 @@
{ lib, ... }:
with lib.our.disko;
let
inherit (lib) genAttrs flip;
in
{
disko.devices = {
nodev."/" = mkTmpfs "2G";
disk.stick = mkDisk "some-usb-stick" {
partitions = {
boot = mkESP "64M" "/boot/efi";
main = mkBtrfsPart "100%" "/media/main" {
subvolumes = mkBtrfsSubvols {
"/boot" = { };
"/etc/ssh" = { };
"/nix" = { };
"/persist" = { };
};
};
};
};
};
fileSystems = flip genAttrs (_: { neededForBoot = true; }) [
"/persist"
"/etc/ssh"
];
}