update nixpkgs, home-manager, remove root password, refactor, use tmpfs, c2: use disk labels

This commit is contained in:
Henri Dohmen 2025-04-19 22:36:22 +02:00
parent 59a71b5cf2
commit 62d3765e58
8 changed files with 109 additions and 39 deletions

View file

@ -1,31 +1,54 @@
{ lib, ... }:
{
nix.settings = {
experimental-features = [
"nix-command"
"flakes"
];
trusted-users = [
"root"
"@wheel"
];
auto-optimise-store = true;
lib,
inputs,
config,
...
}:
{
config = {
nix.settings = {
experimental-features = [
"nix-command"
"flakes"
];
trusted-users = [
"root"
"@wheel"
];
auto-optimise-store = true;
};
programs.nix-ld.enable = true;
nixpkgs.config.allowUnfree = false;
nixpkgs.config.allowUnfreePredicate =
pkg:
builtins.elem (lib.getName pkg) [
"nvidia-x11"
"nvidia-settings"
"vscode"
"obsidian"
"steam"
"steam-unwrapped"
"gateway" # jetbrains
"spotify"
"rust-rover"
];
home.home.stateVersion = config.system.stateVersion; # is this safe?
};
programs.nix-ld.enable = true;
imports = [
inputs.home-manager.nixosModules.home-manager
];
nixpkgs.config.allowUnfree = false;
nixpkgs.config.allowUnfreePredicate =
pkg:
builtins.elem (lib.getName pkg) [
"nvidia-x11"
"nvidia-settings"
"vscode"
"obsidian"
"steam"
"steam-unwrapped"
"gateway" # jetbrains
"spotify"
"rust-rover"
];
# I don't think this will ever be multi user,
# no need to seperate home-manager. `home` is used
# in users.nix, I should prbably refactor...
options = {
home = lib.mkOption {
type = lib.types.attrs;
default = { };
};
};
}