initial disko config

This commit is contained in:
twoneis 2025-01-08 18:13:44 +01:00
parent c3f1d785e4
commit 3abec60b83
4 changed files with 61 additions and 28 deletions

54
devices/inkvine/disko.nix Normal file
View file

@ -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";
};
};
};
};
};
};
};
};
};
};
}

View file

@ -3,7 +3,7 @@
apps.enable = true; apps.enable = true;
niri.enable = true; niri.enable = true;
extraLayout.enable = true; extraLayout.enable = true;
secureboot.enable = true; secureboot.enable = false;
containers.enable = true; containers.enable = true;
stateVersion = "24.05"; stateVersion = "24.05";

View file

@ -13,6 +13,11 @@
url = "github:nixos/nixos-hardware"; url = "github:nixos/nixos-hardware";
}; };
disko = {
url = "github:nix-community/disko/latest";
inputs.nixpkgs.follows = "nixpkgs";
}
nur = { nur = {
url = "github:nix-community/nur"; url = "github:nix-community/nur";
}; };

View file

@ -5,36 +5,10 @@
niri.nixosModules.niri niri.nixosModules.niri
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
lanzaboote.nixosModules.lanzaboote lanzaboote.nixosModules.lanzaboote
disko.nixosModules.disko
]; ];
in { in {
nixosConfigurations = { 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 # Framework Laptop 13
# AMD Ryzen 5 7640U # AMD Ryzen 5 7640U
# AMD Radeon 760M # AMD Radeon 760M