blob: 5ae0116de300d874749d51f6416430d53c10f151 [file] [log] [blame]
Skyler Greybcb2cb72022-08-21 07:24:35 +01001{
2 pkgs,
3 config,
4 username,
5 ...
6}: {
7 config = {
8 users.mutableUsers = false;
Skyler Grey6aa7c262022-08-20 22:22:03 +01009
Skyler Greybcb2cb72022-08-21 07:24:35 +010010 users.users.${username} = {
11 isNormalUser = true;
Skyler Grey7bd7cb22022-09-01 23:41:57 +010012 extraGroups = ["wheel" "kvm" "docker" "containerd" "dialout" "libvirtd" "video" "tty" config.users.groups.keys.name];
Skyler Greybcb2cb72022-08-21 07:24:35 +010013 shell = pkgs.zsh;
Skyler Grey7bd7cb22022-09-01 23:41:57 +010014 passwordFile = config.sops.secrets.password.path;
Skyler Greybcb2cb72022-08-21 07:24:35 +010015 };
16
Skyler Grey7bd7cb22022-09-01 23:41:57 +010017 environment.persistence."/nix/persist".users.${username}.directories = ["Code" "Documents" "Pictures"];
18 sops.secrets.password = {
19 mode = "0400";
20 neededForUsers = true;
21 };
Skyler Greybcb2cb72022-08-21 07:24:35 +010022 };
Skyler Grey6aa7c262022-08-20 22:22:03 +010023}