chore: refactor system modules

This commit is contained in:
2025-07-05 00:02:39 +02:00
parent d64caa86ec
commit 15a39660eb
56 changed files with 549 additions and 475 deletions

31
system/users/phundrak.nix Normal file
View File

@@ -0,0 +1,31 @@
{
lib,
config,
pkgs,
...
}:
with lib; let
cfg = config.system.users;
in {
options.system.users = {
root.disablePassword = mkEnableOption "Disables root password";
phundrak.enable = mkEnableOption "Enables users phundrak";
};
config = {
users.users = {
root = {
hashedPassword = mkIf cfg.root.disablePassword "*";
shell = pkgs.zsh;
};
phundrak = mkIf cfg.phundrak.enable {
isNormalUser = true;
description = "Lucien Cartier-Tilet";
extraGroups = ["networkmanager" "wheel" "docker" "dialout" "podman"];
shell = pkgs.zsh;
openssh.authorizedKeys.keyFiles = lib.filesystem.listFilesRecursive ./keys;
};
};
programs.zsh.enable = true;
};
}