mirror of
https://github.com/buckley310/nixos-config.git
synced 2024-11-09 18:47:02 +00:00
move user accounts to separate file
This commit is contained in:
parent
066013cd08
commit
94e235add8
2 changed files with 22 additions and 14 deletions
|
@ -21,10 +21,7 @@
|
||||||
(x: (pkgs.writeShellScriptBin "sc-${x}" "nixos-rebuild ${x} --refresh --flake github:buckley310/nixos-config"))
|
(x: (pkgs.writeShellScriptBin "sc-${x}" "nixos-rebuild ${x} --refresh --flake github:buckley310/nixos-config"))
|
||||||
[ "switch" "build" "boot" ];
|
[ "switch" "build" "boot" ];
|
||||||
|
|
||||||
systemd.tmpfiles.rules = [
|
systemd.tmpfiles.rules = [ "e /nix/var/log - - - 30d" ];
|
||||||
"e /nix/var/log - - - 30d"
|
|
||||||
"e /home/sean/Downloads - - - 9d"
|
|
||||||
];
|
|
||||||
|
|
||||||
zramSwap.enable = true;
|
zramSwap.enable = true;
|
||||||
|
|
||||||
|
@ -61,14 +58,4 @@
|
||||||
publish.addresses = true;
|
publish.addresses = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
users.users.sean = {
|
|
||||||
isNormalUser = true;
|
|
||||||
extraGroups = [ "wheel" "audio" "video" "networkmanager" "dialout" "input" "wireshark" ];
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIqWHzIXaF88Y8+64gBlLbZ5ZZcLl08kTHG1clHd7gaq desktop"
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJlMPWSVyDNAvXYtpXCI/geCeUEMbL9Nthm9B0zg1sIy sean@hp"
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDuuBHq3x28cdQ0JWAZ0R+2rVlRoPnA+MOvpdF5rraGp sean@lenny"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
21
modules/sean.nix
Normal file
21
modules/sean.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIqWHzIXaF88Y8+64gBlLbZ5ZZcLl08kTHG1clHd7gaq desktop"
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJlMPWSVyDNAvXYtpXCI/geCeUEMbL9Nthm9B0zg1sIy sean@hp"
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDuuBHq3x28cdQ0JWAZ0R+2rVlRoPnA+MOvpdF5rraGp sean@lenny"
|
||||||
|
];
|
||||||
|
in
|
||||||
|
{
|
||||||
|
users.users.root.openssh.authorizedKeys =
|
||||||
|
if config.sconfig.profile == "server"
|
||||||
|
then { inherit keys; } else { };
|
||||||
|
|
||||||
|
users.users.sean = {
|
||||||
|
isNormalUser = true;
|
||||||
|
extraGroups = [ "wheel" "audio" "video" "networkmanager" "dialout" "input" "wireshark" ];
|
||||||
|
openssh.authorizedKeys = { inherit keys; };
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.tmpfiles.rules = [ "e /home/sean/Downloads - - - 9d" ];
|
||||||
|
}
|
Loading…
Reference in a new issue