summaryrefslogtreecommitdiff
path: root/modules/root/normaluser.nix
diff options
context:
space:
mode:
authorTim Keller <tjk@tjkeller.xyz>2025-08-21 12:27:51 -0500
committerTim Keller <tjk@tjkeller.xyz>2025-08-21 12:27:51 -0500
commit86fb7036cb4279abfc4ffc2bfa6b3a432c8700b5 (patch)
treebcde8a15f5cec938d3f4653863b0f6309bc65626 /modules/root/normaluser.nix
parent078e8ea33d29af21bad55313d75d716db8d5a617 (diff)
downloadnixos-86fb7036cb4279abfc4ffc2bfa6b3a432c8700b5.tar.xz
nixos-86fb7036cb4279abfc4ffc2bfa6b3a432c8700b5.zip
refactor project to prioritize correctness. place custom nixos options into existing 'modules' and prefix them with '_'. use _archetypes module for software collections, system profiles, etc. personal configs moved to _archetypes.tjkeller. probably changed or fixed or broke a few other things in the process
Diffstat (limited to 'modules/root/normaluser.nix')
-rw-r--r--modules/root/normaluser.nix31
1 files changed, 0 insertions, 31 deletions
diff --git a/modules/root/normaluser.nix b/modules/root/normaluser.nix
deleted file mode 100644
index 50e9236..0000000
--- a/modules/root/normaluser.nix
+++ /dev/null
@@ -1,31 +0,0 @@
-{ lib, config, userDetails, ... }: {
- options = {
- users.setPassword.enable = lib.mkEnableOption "set users password. requires hashed root password from sops";
- };
-
- config = {
- # Load hashed root password secret
- sops.secrets.hashed-root-password = lib.mkIf config.users.setPassword.enable {
- sopsFile = ./resources/secrets/hashed-root-password.yaml;
- neededForUsers = true;
- };
-
- # Set hashed password file if the setPassword option is enabled
- users.users.root.hashedPasswordFile = lib.mkIf config.users.setPassword.enable config.sops.secrets.hashed-root-password.path;
-
- # Setup normal user
- users.users.${userDetails.username} = {
- home = userDetails.home;
- description = userDetails.fullname;
- isNormalUser = true;
- extraGroups = [
- "i2c"
- "libvirtd"
- "nixbld"
- "video"
- "wheel"
- ];
- hashedPasswordFile = lib.mkIf config.users.setPassword.enable config.sops.secrets.hashed-root-password.path;
- };
- };
-}