nixos-config/base/users.nix

29 lines
680 B
Nix
Raw Normal View History

2021-02-14 13:18:13 +01:00
{
2022-04-10 11:54:58 +02:00
config,
lib,
pkgs,
...
}: let
secrets = config.my.secrets;
in {
2021-02-14 13:18:13 +01:00
users.mutableUsers = false;
users.users.root = {
passwordFile = config.age.secrets."users/root-hashed-password".path;
2021-02-14 13:18:13 +01:00
};
users.users.alarsyo = {
passwordFile = config.age.secrets."users/alarsyo-hashed-password".path;
2021-02-14 13:18:13 +01:00
isNormalUser = true;
2021-02-19 21:46:19 +01:00
extraGroups = [
"media"
2021-04-16 21:33:48 +02:00
"networkmanager"
"video" # for `light` permissions
"docker"
2021-02-19 21:46:19 +01:00
"wheel" # Enable sudo for the user.
];
2021-02-14 13:18:13 +01:00
shell = pkgs.fish;
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3rrF3VSWI4n4cpguvlmLAaU3uftuX4AVV/39S/8GO9 alarsyo@thinkpad"
];
};
}