user
This commit is contained in:
parent
2aa265b82a
commit
20a6964894
4 changed files with 37 additions and 3 deletions
|
|
@ -8,8 +8,9 @@
|
|||
./bluetooth.nix
|
||||
./btrfs.nix
|
||||
./fonts.nix
|
||||
# ./nix.nix
|
||||
# ./steam.nix
|
||||
./nix.nix
|
||||
./users.nix
|
||||
./steam.nix
|
||||
];
|
||||
|
||||
system.stateVersion = "24.11";
|
||||
|
|
|
|||
|
|
@ -3,7 +3,6 @@
|
|||
hideMounts = true;
|
||||
directories = [
|
||||
"/etc/NetworkManager/system-connections"
|
||||
"/var/lib/bluetooth"
|
||||
"/var/lib/systemd/coredump"
|
||||
"/var/lib/bluetooth"
|
||||
];
|
||||
|
|
|
|||
30
system/users.nix
Normal file
30
system/users.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{
|
||||
conf,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
users.mutableUsers = false;
|
||||
users.users = {
|
||||
${conf.user} = {
|
||||
isNormalUser = true;
|
||||
uid = conf.uid;
|
||||
extraGroups = ["wheel" "networkmanager"];
|
||||
hashedPasswordFile = config.sops.secrets."user/hashedPassword".path;
|
||||
};
|
||||
};
|
||||
|
||||
home-manager.users = let
|
||||
hm = import ../home;
|
||||
in {
|
||||
${conf.user} = {
|
||||
imports = hm.user;
|
||||
home.username = conf.user;
|
||||
home.homeDirectory = conf.home;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets."user/password" = {
|
||||
sopsFile = ../hosts/${conf.hostname}/secrets/default.yml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue