major improvements on purity

This commit is contained in:
2025-02-01 23:26:22 -05:00
parent 0667de38fe
commit 2084f190da
4 changed files with 54 additions and 46 deletions

View File

@@ -14,9 +14,19 @@
./distrobox.nix
./vm.nix
inputs.agenix.nixosModules.default
inputs.nixos-hardware.nixosModules.common-pc-ssd
];
nixpkgs.config.allowUnfreePredicate =
pkg:
builtins.elem (lib.getName pkg) [
"steam"
"steam-original"
"steam-unwrapped"
"steam-run"
];
nix = {
# optimize the store
optimise.automatic = true;
@@ -59,6 +69,7 @@
kernelModules = [
"ip_tables"
"iptable_nat"
"msr"
];
};

12
etcnixos/flake.lock generated
View File

@@ -167,11 +167,11 @@
},
"nixos-hardware": {
"locked": {
"lastModified": 1737751639,
"narHash": "sha256-ZEbOJ9iT72iwqXsiEMbEa8wWjyFvRA9Ugx8utmYbpz4=",
"lastModified": 1738391520,
"narHash": "sha256-6HI58PKjddsC0RA0gBQlt6ox47oH//jLUHwx05RO8g0=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "dfad538f751a5aa5d4436d9781ab27a6128ec9d4",
"rev": "34b64e4e1ddb14e3ffc7db8d4a781396dbbab773",
"type": "github"
},
"original": {
@@ -183,11 +183,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1737672001,
"narHash": "sha256-YnHJJ19wqmibLQdUeq9xzE6CjrMA568KN/lFPuSVs4I=",
"lastModified": 1738277201,
"narHash": "sha256-6L+WXKCw5mqnUIExvqkD99pJQ41xgyCk6z/H9snClwk=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "035f8c0853c2977b24ffc4d0a42c74f00b182cd8",
"rev": "666e1b3f09c267afd66addebe80fb05a5ef2b554",
"type": "github"
},
"original": {

View File

@@ -29,32 +29,29 @@
}@inputs:
let
username = "primary";
hostname = nixpkgs.lib.strings.removeSuffix "\n" (builtins.readFile /etc/hostname);
system = "x86_64-linux";
pkgs = import nixpkgs {
# config.allowUnfreePredicate =
# pkg:
# builtins.elem (nixpkgs.lib.getName pkg) [
# "steam-unwrapped"
# "steam"
# ];
# idk pkgs.wivrn pulls a bunch of cuda stuff even though cudaSupport is disabled?
config.allowUnfree = true;
config.cudaSupport = false;
};
in
{
nixosConfigurations.${hostname} = nixpkgs.lib.nixosSystem {
# desktop
nixosConfigurations.yarn = nixpkgs.lib.nixosSystem {
specialArgs = {
inherit inputs username hostname;
hostname = "yarn";
inherit inputs username;
};
inherit pkgs;
modules = [
./system-${hostname}.nix
agenix.nixosModules.default
./system-yarn.nix
];
};
# laptop
nixosConfigurations.mreow = nixpkgs.lib.nixosSystem {
specialArgs = {
hostname = "mreow";
inherit inputs username;
};
modules = [
./system-mreow.nix
];
};
};