2023-08-22 13:08:31 -06:00
|
|
|
{ pkgs, realUsers, forEachUser, kanivanKeys, deanKeys, alexKeys, allKeys, ... }:
|
|
|
|
let
|
2021-07-10 15:27:14 -06:00
|
|
|
extraGroups = [
|
|
|
|
"audio"
|
|
|
|
"adbusers"
|
|
|
|
"disk"
|
|
|
|
"docker"
|
|
|
|
"networkmanager"
|
2022-04-04 15:51:14 -06:00
|
|
|
"openrazer"
|
2021-07-10 15:27:14 -06:00
|
|
|
"plugdev"
|
2023-08-03 22:01:56 -06:00
|
|
|
"syncthing"
|
2021-07-10 15:27:14 -06:00
|
|
|
"systemd-journal"
|
|
|
|
"video"
|
|
|
|
"wheel"
|
|
|
|
];
|
|
|
|
userDefaults = {
|
|
|
|
inherit extraGroups;
|
|
|
|
group = "users";
|
|
|
|
isNormalUser = true;
|
|
|
|
createHome = true;
|
|
|
|
shell = pkgs.zsh;
|
|
|
|
};
|
2023-08-22 13:08:31 -06:00
|
|
|
in
|
|
|
|
{
|
|
|
|
security.sudo.wheelNeedsPassword = false;
|
|
|
|
users.users = {
|
2023-08-03 22:01:56 -06:00
|
|
|
syncthing = {
|
2023-08-05 19:31:34 -06:00
|
|
|
extraGroups = [ "syncthing" "wheel" ];
|
2023-08-03 22:01:56 -06:00
|
|
|
home = "/var/lib/syncthing";
|
|
|
|
createHome = true;
|
|
|
|
};
|
2023-07-28 10:53:50 -06:00
|
|
|
imalison = userDefaults // {
|
|
|
|
name = "imalison";
|
|
|
|
shell = pkgs.zsh;
|
2023-08-22 13:08:31 -06:00
|
|
|
openssh.authorizedKeys.keys = kanivanKeys;
|
2021-07-10 15:27:14 -06:00
|
|
|
};
|
|
|
|
kat = userDefaults // {
|
|
|
|
name = "kat";
|
|
|
|
shell = pkgs.zsh;
|
2023-08-22 13:08:31 -06:00
|
|
|
openssh.authorizedKeys.keys = kanivanKeys;
|
2021-07-10 15:27:14 -06:00
|
|
|
};
|
2023-07-19 12:43:03 -06:00
|
|
|
dean = userDefaults // {
|
|
|
|
name = "dean";
|
|
|
|
shell = pkgs.zsh;
|
2023-08-22 13:08:31 -06:00
|
|
|
openssh.authorizedKeys.keys = kanivanKeys ++ deanKeys;
|
2023-07-19 12:43:03 -06:00
|
|
|
};
|
2023-08-03 15:20:23 -06:00
|
|
|
alex = userDefaults // {
|
|
|
|
name = "alex";
|
|
|
|
shell = pkgs.zsh;
|
2023-08-22 13:08:31 -06:00
|
|
|
openssh.authorizedKeys.keys = kanivanKeys ++ alexKeys;
|
2023-08-03 15:20:23 -06:00
|
|
|
};
|
2021-07-10 15:27:14 -06:00
|
|
|
};
|
|
|
|
|
2023-08-20 02:54:19 -06:00
|
|
|
nix.settings.trusted-users = realUsers;
|
2023-08-22 13:08:31 -06:00
|
|
|
nix.sshServe = {
|
|
|
|
enable = true;
|
|
|
|
keys = allKeys;
|
|
|
|
};
|
2023-08-20 02:54:19 -06:00
|
|
|
|
|
|
|
home-manager.users = forEachUser (import ./home-manager.nix);
|
2021-07-10 15:27:14 -06:00
|
|
|
}
|