modularized user

This commit is contained in:
Bryan Ramos 2024-01-27 14:22:57 -05:00
parent 41c07d0fc1
commit 09fdfeed11
Signed by: bryan
GPG key ID: 6ABDCD144D6643C8
3 changed files with 25 additions and 10 deletions

View file

@ -1,4 +1,4 @@
{ pkgs, lib, ... }:
{ pkgs, lib, config, ... }:
{ system.stateVersion = "22.11";
@ -50,7 +50,15 @@
};
# Users
users.users = import ./user;
users.users = {
${config.user.name} = {
isNormalUser = true;
extraGroups = config.user.groups;
openssh.authorizedKeys = lib.mkIf (config.user.name == "bryan") {
keys = config.user.sshKeys;
};
};
};
security.sudo = {
wheelNeedsPassword = false;