Skyler Grey | bcb2cb7 | 2022-08-21 07:24:35 +0100 | [diff] [blame] | 1 | { |
| 2 | pkgs, |
| 3 | config, |
| 4 | username, |
| 5 | ... |
| 6 | }: { |
| 7 | config = { |
| 8 | users.mutableUsers = false; |
Skyler Grey | 6aa7c26 | 2022-08-20 22:22:03 +0100 | [diff] [blame] | 9 | |
Skyler Grey | bcb2cb7 | 2022-08-21 07:24:35 +0100 | [diff] [blame] | 10 | users.users.${username} = { |
| 11 | isNormalUser = true; |
Skyler Grey | 7bd7cb2 | 2022-09-01 23:41:57 +0100 | [diff] [blame] | 12 | extraGroups = ["wheel" "kvm" "docker" "containerd" "dialout" "libvirtd" "video" "tty" config.users.groups.keys.name]; |
Skyler Grey | bcb2cb7 | 2022-08-21 07:24:35 +0100 | [diff] [blame] | 13 | shell = pkgs.zsh; |
Skyler Grey | 7bd7cb2 | 2022-09-01 23:41:57 +0100 | [diff] [blame] | 14 | passwordFile = config.sops.secrets.password.path; |
Skyler Grey | bcb2cb7 | 2022-08-21 07:24:35 +0100 | [diff] [blame] | 15 | }; |
| 16 | |
Skyler Grey | 7bd7cb2 | 2022-09-01 23:41:57 +0100 | [diff] [blame] | 17 | environment.persistence."/nix/persist".users.${username}.directories = ["Code" "Documents" "Pictures"]; |
| 18 | sops.secrets.password = { |
| 19 | mode = "0400"; |
| 20 | neededForUsers = true; |
| 21 | }; |
Skyler Grey | bcb2cb7 | 2022-08-21 07:24:35 +0100 | [diff] [blame] | 22 | }; |
Skyler Grey | 6aa7c26 | 2022-08-20 22:22:03 +0100 | [diff] [blame] | 23 | } |