From 325bc887efcffa230af0052f79ebacf8a5104d0c Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Wed, 8 Apr 2026 22:36:49 -0500 Subject: [PATCH 1/4] fix (zed): nixd home-manager autocomplete --- programs/zed.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/programs/zed.nix b/programs/zed.nix index 1aceb66..0fa72a1 100644 --- a/programs/zed.nix +++ b/programs/zed.nix @@ -1,4 +1,4 @@ -{ pkgs, ... }: { +{ pkgs, hostname, ... }: { programs.zed-editor = { enable = true; package = null; @@ -60,8 +60,8 @@ lsp = { nil = { settings.nix.flake.autoArchive = true; }; nixd = { - settings.options.home-manager.expr = - "(builtins.getFlake (builtins.toString ./.)).homeConfigurations..options"; + settings.options.home-manager.expr = '' + (builtins.getFlake (builtins.toString ~/.config/home-manager)).homeConfigurations."millironx@${hostname}".options''; }; texlab = { settings = { From 20efe752c20cfe863491a148ce7a87d27cc96926 Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Wed, 8 Apr 2026 22:37:16 -0500 Subject: [PATCH 2/4] chore (odyssey): Update AnythingLLM container --- homes/odyssey.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homes/odyssey.nix b/homes/odyssey.nix index 1d50f04..fd1c201 100644 --- a/homes/odyssey.nix +++ b/homes/odyssey.nix @@ -19,7 +19,7 @@ anythingllm = { autoStart = true; containerConfig = { - image = "docker.io/mintplexlabs/anythingllm:1.9"; + image = "docker.io/mintplexlabs/anythingllm:latest"; addHosts = [ "ollama.millironx.local:host-gateway" ]; publishPorts = [ "3001:3001" ]; volumes = From 804132ae4f435a2d54bc38d201c1f60d952e926c Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Wed, 8 Apr 2026 22:39:31 -0500 Subject: [PATCH 3/4] feat (common): Add ssh support This removes GPG agent support for SSH. The GPG agent will still be in charge of signing git commits. Default user keys will still be used for encryption (i.e. agenix) purposes. --- homes/common.nix | 1 + programs/ssh.nix | 72 ++++++++++++++++++++++++++++++++++++++++++ services/gpg-agent.nix | 2 +- 3 files changed, 74 insertions(+), 1 deletion(-) create mode 100644 programs/ssh.nix diff --git a/homes/common.nix b/homes/common.nix index 3836d34..389c618 100644 --- a/homes/common.nix +++ b/homes/common.nix @@ -6,6 +6,7 @@ ./../programs/git.nix ./../programs/lsd.nix ./../programs/neovim.nix + ./../programs/ssh.nix ./../programs/starship.nix ./../programs/tmux.nix ./../programs/yt-dlp.nix diff --git a/programs/ssh.nix b/programs/ssh.nix new file mode 100644 index 0000000..a768c6b --- /dev/null +++ b/programs/ssh.nix @@ -0,0 +1,72 @@ +{ pkgs, lib, config, hostname, ... }: +let + sshIdPath = host: "~/.ssh/id_ed25519__${host}"; + tailnetConfig = host: { identityFile = sshIdPath host; }; + gitConfig = host: tailnetConfig host // { user = "git"; }; + tailnetHosts = [ "anderson" "mcentire" "bosephus" ]; + gitHosts = [ "github.com" "gitlab.com" "codeberg.org" "code.millironx.com" ]; + tailnetMatchBlocks = + lib.genAttrs (lib.lists.remove hostname tailnetHosts) tailnetConfig; + gitMatchBlocks = lib.genAttrs gitHosts gitConfig // { + "code.millironx.com" = (gitConfig "code.millironx.com") // { + proxyCommand = "ssh anderson -W localhost:2222"; + }; + }; +in { + programs.ssh = { + enable = true; + enableDefaultConfig = false; + matchBlocks = { + "*" = { identitiesOnly = true; }; + "aahz" = { + hostname = "nistac-108-37.dhcp.ksu.edu"; + user = "tchristensen"; + identityFile = sshIdPath "aahz"; + }; + "skeeve" = { + hostname = "129.130.108.157"; + user = "tchristensen"; + identityFile = sshIdPath "skeeve"; + }; + "ceres" = { + hostname = "ceres.scinet.usda.gov"; + user = "thomas.christensen"; + identitiesOnly = false; + serverAliveInterval = 20; + serverAliveCountMax = 30; + extraOptions = { TCPKeepAlive = "yes"; }; + }; + "atlas" = { + hostname = "Atlas-login-1.hpc.msstate.edu"; + user = "thomas.christensen"; + identitiesOnly = false; + serverAliveInterval = 20; + serverAliveCountMax = 30; + extraOptions = { TCPKeepAlive = "yes"; }; + }; + "atlas-dtn" = { + hostname = "Atlas-dtn.hpc.msstate.edu"; + user = "thomas.christensen"; + identitiesOnly = false; + }; + "code.millironx.com" = { + proxyCommand = "ssh anderson -W localhost:2222"; + }; + } // tailnetMatchBlocks // gitMatchBlocks; + }; + + home.packages = let + # Answer no to overwrite questions + keygen = host: '' + yes "n" | \ + ssh-keygen \ + -t ed25519 \ + -f ~/.ssh/id_ed25519__${host} \ + -C "millironx@${hostname}" \ + -N "" + ''; + in [ + (pkgs.writeShellScriptBin "ssh-bootstrap-keys" + (builtins.concatStringsSep "\n" (map keygen (tailnetHosts ++ gitHosts)))) + ]; +} diff --git a/services/gpg-agent.nix b/services/gpg-agent.nix index e34906a..e4a7939 100644 --- a/services/gpg-agent.nix +++ b/services/gpg-agent.nix @@ -2,7 +2,7 @@ services.gpg-agent = { enable = true; enableBashIntegration = true; - enableSshSupport = true; + enableSshSupport = false; enableZshIntegration = true; defaultCacheTtl = 604800; maxCacheTtl = 604800; From 16ebf17d5120eeb82b751c8914375c513550f2a6 Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Mon, 13 Apr 2026 11:36:21 -0500 Subject: [PATCH 4/4] fix (ssh): incorrect hostname for code.millironx.com --- programs/ssh.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/programs/ssh.nix b/programs/ssh.nix index a768c6b..a094d44 100644 --- a/programs/ssh.nix +++ b/programs/ssh.nix @@ -10,6 +10,7 @@ let gitMatchBlocks = lib.genAttrs gitHosts gitConfig // { "code.millironx.com" = (gitConfig "code.millironx.com") // { proxyCommand = "ssh anderson -W localhost:2222"; + hostname = "code.millironx.com"; }; }; in {