System/nixos/modules/user.nix
2025-01-08 23:16:50 -05:00

36 lines
693 B
Nix

{
inputs,
mutableUsers ? false,
username ? "nathan",
homedir ? "/home/nathan",
}:
{
config,
lib,
pkgs,
...
}:
{
security.polkit = {
enable = true;
};
users = {
inherit mutableUsers;
users.${username} = {
home = homedir;
description = "Nathan McCarty";
shell = pkgs.nushell;
isNormalUser = true;
extraGroups = [
"wheel"
];
hashedPassword = "$6$ShBAPGwzKZuB7eEv$cbb3erUqtVGFo/Vux9UwT2NkbVG9VGCxJxPiZFYL0DIc3t4GpYxjkM0M7fFnh.6V8MoSKLM/TvOtzdWbYwI58.";
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEtE+KjKuHUj5bKKQBDKqhO5dpEQf8E8u1G6kRj7y6dI nathan@nixos"
];
};
};
}