NixOS/system/user.nix

23 lines
530 B
Nix
Raw Normal View History

2024-06-12 18:09:56 +07:00
{ pkgs, config, lib, ... }:
2024-06-12 09:54:11 +07:00
let
2024-06-12 18:09:56 +07:00
user = config.profile.user.name;
fullName = config.profile.user.fullName;
2024-06-12 09:54:11 +07:00
in
{
users.users.${user} = {
isNormalUser = true;
description = fullName;
2024-06-12 18:09:56 +07:00
extraGroups = [ "networkmanager" "wheel" "docker" "adbusers" "scanner" "lp" "podman" ];
2024-06-12 09:54:11 +07:00
shell = pkgs.zsh;
};
users.groups.work = {
name = "work";
gid = 5555;
members = [ user ];
};
nix.settings.trusted-users = [ user ];
2024-06-12 18:09:56 +07:00
services.getty.autologinUser = lib.mkIf config.profile.user.getty.autoLogin user;
2024-06-12 09:54:11 +07:00
}