nixos/modules/base/users.nix

29 lines
934 B
Nix
Raw Normal View History

2023-08-01 15:35:09 +02:00
{ pkgs, ... }: {
users = {
# Don't allow imperative modifications to users (incompatible with impermanence)
mutableUsers = false;
users = {
root = {
passwordFile = "/nix/persist/passwordfile";
};
caspervk = {
isNormalUser = true;
description = "Casper V. Kristensen";
passwordFile = "/nix/persist/passwordfile";
extraGroups = [
"networkmanager"
2023-08-01 16:55:53 +02:00
"wheel" # allows sudo
"video" # allows controlling brightness
2023-08-01 15:35:09 +02:00
# todo: docker, systemd-journal, audio, input, power, nix ?
];
uid = 1000;
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPB/qr63FB0ZqOe/iZGwIKNHD8a1Ud/mXVjQPmpIG7pM caspervk@omega"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAII71DKQziktCkyMAmL25QKRK6nG2uJDkQXioIZp5JkMZ caspervk@zeta"
];
2023-08-01 16:55:53 +02:00
packages = with pkgs; [ ];
2023-08-01 15:35:09 +02:00
};
};
};
}