diff --git a/features/users.nix b/features/users.nix new file mode 100644 index 0000000..031cdb7 --- /dev/null +++ b/features/users.nix @@ -0,0 +1,16 @@ +{ config, ... }: +{ + users = { + mutableUsers = false; + + users.frank = { + isNormalUser = true; + description = "Frank LoTurco"; + hashedPasswordFile = config.sops.secrets.password_hash.path; + + extraGroups = [ + "wheel" + ]; + }; + }; +} diff --git a/flake.nix b/flake.nix index d89d18e..978c72c 100644 --- a/flake.nix +++ b/flake.nix @@ -48,7 +48,6 @@ nix-flatpak = { url = "github:gmodena/nix-flatpak/?ref=latest"; - inputs.nixpkgs.follows = "nixpkgs"; }; appimage-manager = { diff --git a/hosts/shared/nixos-pc.nix b/hosts/shared/nixos-pc.nix index 2925bbe..5b63f88 100644 --- a/hosts/shared/nixos-pc.nix +++ b/hosts/shared/nixos-pc.nix @@ -16,6 +16,7 @@ ../../features/i18n.nix ../../features/sudo.nix ../../features/sops.nix + ../../features/users.nix ./nix-package-manager.nix ]; @@ -169,20 +170,6 @@ }; }; - users.users.frank = { - isNormalUser = true; - description = "Frank LoTurco"; - hashedPassword = config.sops.secrets.password_hash.path; - - extraGroups = [ - "networkmanager" - "wheel" - "input" - "video" - "uinput" - ]; - }; - nixpkgs = { # Fix msitools compiling and failing it's test-suite. overlays = [ diff --git a/hosts/shared/nixos-server.nix b/hosts/shared/nixos-server.nix index d1de3cf..5ae4f29 100644 --- a/hosts/shared/nixos-server.nix +++ b/hosts/shared/nixos-server.nix @@ -14,6 +14,7 @@ ../../features/i18n.nix ../../features/sudo.nix ../../features/sops.nix + ../../features/users.nix ./nix-package-manager.nix ]; @@ -73,17 +74,6 @@ }; }; - users.users.frank = { - isNormalUser = true; - description = "Frank LoTurco"; - hashedPassword = config.sops.secrets.password_hash.path; - - extraGroups = [ - "wheel" - "libvirtd" - ]; - }; - environment = { systemPackages = import ../../features/common-pkgs.nix { inherit pkgs; }