feat(users): add shell module, simplify users module
This commit is contained in:
parent
c56e3e5eba
commit
f7d404494f
2 changed files with 18 additions and 7 deletions
|
@ -6,13 +6,11 @@ let
|
|||
in
|
||||
{
|
||||
flake.modules.nixos.default =
|
||||
{ pkgs, config, ... }:
|
||||
{ config, ... }:
|
||||
{
|
||||
#TODO: move sudo/security options elsewhere
|
||||
# security.sudo.wheelNeedsPassword = false;
|
||||
# nix.settings.trusted-users = [ "@wheel" ];
|
||||
#TODO: move to shell config
|
||||
# programs.${owner.shell}.enable = true;
|
||||
#TODO: move ssh key settings elsewhere
|
||||
# users.users.root.openssh.authorizedKeys.keys = [ owner.pubkey ];
|
||||
users = {
|
||||
|
@ -22,14 +20,10 @@ in
|
|||
_: value: {
|
||||
isNormalUser = true;
|
||||
extraGroups = optional (value.primary or false) "wheel";
|
||||
# FIXME: remove when we make the shell module
|
||||
ignoreShellProgramCheck = true;
|
||||
shell = pkgs.${value.shell};
|
||||
openssh.authorizedKeys.keys = [ value.pubkey ];
|
||||
}
|
||||
);
|
||||
};
|
||||
|
||||
home-manager.users = forAllUsers' (
|
||||
name: _: {
|
||||
home.username = name;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue