default.nix (672B)
1 { config, lib, pkgs, ... }: 2 3 let 4 inherit (lib) lists attrsets mkIf optionals versionOlder importTOML; 5 metadata = importTOML ../../ops/hosts.toml; 6 in 7 { 8 users.users.root = { 9 shell = mkIf config.programs.zsh.enable pkgs.zsh; 10 openssh.authorizedKeys.keys = metadata.ssh.keys.root; 11 }; 12 home-manager.users.root = lib.mkMerge ( 13 [ 14 (import ../vincent/core/zsh.nix) 15 (import ../vincent/core/ssh.nix) 16 ] 17 ++ optionals (versionOlder config.system.nixos.release "21.11") [{ 18 # manpages are broken on 21.05 and home-manager (for some reason..) 19 manual.manpages.enable = false; 20 }] ++ [{ 21 home.stateVersion = "22.05"; 22 }] 23 ); 24 }