diff --git a/devices/inkvine/disko.nix b/devices/inkvine/disko.nix new file mode 100644 index 0000000..e2f7984 --- /dev/null +++ b/devices/inkvine/disko.nix @@ -0,0 +1,54 @@ +{ ... }: { + disko.devices = { + disk = { + main = { + type = "disk"; + device = "/dev/nvme0"; + content = { + type = "gpt"; + partitions = { + ESP = { + size = "1G"; + type = "EF00"; + content = { + type = "filesystem"; + format = "vfat"; + mountpoint = "/boot"; + mountOptions = [ "umask=0077" ]; + }; + }; + luks = { + size = "100%"; + content = { + type = "luks"; + name = "crypted"; + settings = { + allowDiscards = true; + }; + content = { + type = "btrfs"; + extraArgs = [ "-f" ]; + subvolumes = { + "/root" = { + mountpoint = "/"; + mountOptions = [ "compress=zstd" "noatime" ]; + }; + "/nix" = { + mountpoint = "/nix"; + mountOptions = [ "compress=zstd" "noatime" ]; + }; + "/swap" = { + mountpoint = "/.swapvol"; + swap.swapfile.size = "8G"; + }; + }; + }; + }; + }; + }; + }; + }; + }; + }; +} + diff --git a/devices/inkvine/options.nix b/devices/inkvine/options.nix index 03fc8ef..3912aa0 100644 --- a/devices/inkvine/options.nix +++ b/devices/inkvine/options.nix @@ -3,7 +3,7 @@ apps.enable = true; niri.enable = true; extraLayout.enable = true; - secureboot.enable = true; + secureboot.enable = false; containers.enable = true; stateVersion = "24.05"; diff --git a/flake.nix b/flake.nix index 347e9b6..9cb2c22 100644 --- a/flake.nix +++ b/flake.nix @@ -13,6 +13,11 @@ url = "github:nixos/nixos-hardware"; }; + disko = { + url = "github:nix-community/disko/latest"; + inputs.nixpkgs.follows = "nixpkgs"; + } + nur = { url = "github:nix-community/nur"; }; diff --git a/outputs.nix b/outputs.nix index db7b6eb..61a712a 100644 --- a/outputs.nix +++ b/outputs.nix @@ -5,36 +5,10 @@ niri.nixosModules.niri home-manager.nixosModules.home-manager lanzaboote.nixosModules.lanzaboote + disko.nixosModules.disko ]; in { nixosConfigurations = { - # AMD Ryzen 5600X - # Nvidia GeForce GTX 1060 (6GB) - # 32GB RAM - ellaca = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = { - inherit inputs; - }; - modules = [ - ./devices/ellaca - ] ++ modules; - }; - - # Zotac ZBOX-CI327NANO - # Intel Celeron N3450 - # Intel HD Graphics 500 - # 8GB RAM - pleniscenta = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = { - inherit inputs; - }; - modules = [ - ./devices/pleniscenta - ] ++ modules; - }; - # Framework Laptop 13 # AMD Ryzen 5 7640U # AMD Radeon 760M