♻️ [shared] Moved users config to base. Use password from Sops
This commit is contained in:
@ -1,6 +1,5 @@
|
|||||||
{
|
{
|
||||||
lib,
|
lib,
|
||||||
config,
|
|
||||||
systemConfig,
|
systemConfig,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
@ -14,13 +13,4 @@
|
|||||||
];
|
];
|
||||||
|
|
||||||
system.stateVersion = systemConfig.version;
|
system.stateVersion = systemConfig.version;
|
||||||
|
|
||||||
users = {
|
|
||||||
mutableUsers = false;
|
|
||||||
users.${systemConfig.username} = {
|
|
||||||
isNormalUser = true;
|
|
||||||
hashedPasswordFile = config.sops.secrets.password-hash.path;
|
|
||||||
extraGroups = [ "wheel" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
@ -6,5 +6,6 @@
|
|||||||
./nixos.nix
|
./nixos.nix
|
||||||
./security
|
./security
|
||||||
./shell.nix
|
./shell.nix
|
||||||
|
./users.nix
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
18
shared/base/modules/users.nix
Normal file
18
shared/base/modules/users.nix
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
{ config, systemConfig, ... }:
|
||||||
|
let
|
||||||
|
username = systemConfig.username;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
users = {
|
||||||
|
mutableUsers = false;
|
||||||
|
users.${username} = {
|
||||||
|
isNormalUser = true;
|
||||||
|
hashedPasswordFile = config.sops.secrets.password-hash.path;
|
||||||
|
description = username;
|
||||||
|
extraGroups = [
|
||||||
|
"networkmanager"
|
||||||
|
"wheel"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
@ -19,7 +19,6 @@
|
|||||||
./sddm.nix
|
./sddm.nix
|
||||||
./security
|
./security
|
||||||
./social.nix
|
./social.nix
|
||||||
./users.nix
|
|
||||||
./qt.nix
|
./qt.nix
|
||||||
./xdg.nix
|
./xdg.nix
|
||||||
./xserver.nix
|
./xserver.nix
|
||||||
|
@ -1,15 +0,0 @@
|
|||||||
{ config, systemConfig, ... }:
|
|
||||||
let
|
|
||||||
username = systemConfig.username;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
users.users.${username} = {
|
|
||||||
isNormalUser = true;
|
|
||||||
hashedPasswordFile = config.sops.secrets.password-hash.path;
|
|
||||||
description = username;
|
|
||||||
extraGroups = [
|
|
||||||
"networkmanager"
|
|
||||||
"wheel"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
Reference in New Issue
Block a user