nix machine / user configurations
1{ 2 config, 3 pkgs, 4 lib, 5 tlib, 6 inputs, 7 ... 8}: 9let 10 l = lib // builtins; 11 12 signKeyText = builtins.readFile ../../secrets/yusdacra.key.pub; 13 personal = import ../../personal.nix; 14 name = personal.name; 15 email = personal.emails.primary; 16in 17{ 18 imports = 19 let 20 modulesToEnable = l.flatten [ 21 [ 22 "zoxide" 23 "fzf" 24 "direnv" 25 "nushell" 26 "tailscale" 27 ] 28 # dev stuff 29 [ 30 "helix" 31 "git" 32 "ssh" 33 ] 34 ]; 35 in 36 l.flatten [ 37 "${inputs.agenix}/modules/age-home.nix" 38 ../../modules/persist/null.nix 39 (tlib.prefixStrings "${inputs.self}/users/modules/" modulesToEnable) 40 ./nsid-tracker.nix 41 ]; 42 43 systemd.user.settings.Manager.DefaultEnvironment = { 44 PATH = "${pkgs.coreutils-full}/bin:$PATH"; 45 }; 46 47 age.identityPaths = [ "${config.home.homeDirectory}/.ssh/id_ed25519" ]; 48 home = { 49 homeDirectory = "/home/dusk"; 50 username = "dusk"; 51 stateVersion = "25.11"; 52 # shell 53 shell.enableShellIntegration = true; 54 shellAliases = { 55 ctl = "systemctl --user"; 56 jtl = "journalctl --user"; 57 g = "git"; 58 e = "hx"; 59 }; 60 sessionVariables = { 61 EDITOR = "hx"; 62 }; 63 }; 64 65 age.secrets.tailscaleAuthKey = { 66 file = ../../secrets/develMobiTailscaleAuthKey.age; 67 mode = "600"; 68 }; 69 services.tailscale = { 70 enable = true; 71 controlServer = "https://vpn.gaze.systems"; 72 authKeyFile = config.age.secrets.tailscaleAuthKey.path; 73 extraUpFlags = [ 74 "--advertise-exit-node=true" 75 "--hostname=dusk-devel-mobi" 76 ]; 77 }; 78 79 programs = { 80 bash = { 81 enable = true; 82 enableCompletion = true; 83 }; 84 tealdeer.enable = true; 85 git = { 86 userName = name; 87 userEmail = email; 88 extraConfig = { 89 gpg.format = "ssh"; 90 commit.gpgsign = true; 91 user.signingkey = signKeyText; 92 }; 93 }; 94 }; 95}