ssh updates

This commit is contained in:
John Lancaster
2026-06-13 10:05:50 -05:00
parent 6e27e92f89
commit 2861c460c2
+34 -42
View File
@@ -126,99 +126,91 @@ in
SetEnv TERM="xterm-256color" SetEnv TERM="xterm-256color"
''; '';
matchBlocks = lib.mkMerge [ settings = lib.mkMerge [
{ {
"john-pc-ubuntu" = { "john-pc-ubuntu" = {
hostname = "192.168.1.85"; HostName = "192.168.1.85";
}; };
"*" = lib.mkMerge [ "*" = lib.mkMerge [
{ {
user = "john"; User = "john";
identityAgent = "${config.home.homeDirectory}/.1password/agent.sock"; IdentityAgent = "${config.home.homeDirectory}/.1password/agent.sock";
compression = false; Compression = false;
serverAliveInterval = 0; ServerAliveInterval = 0;
serverAliveCountMax = 3; ServerAliveCountMax = 3;
identitiesOnly = true; IdentitiesOnly = true;
inherit identityFile; IdentityFile = identityFile;
hashKnownHosts = false; HashKnownHosts = false;
userKnownHostsFile = cfg.knownHostsFile; UserKnownHostsFile = cfg.knownHostsFile;
addKeysToAgent = "yes"; AddKeysToAgent = "yes";
forwardAgent = false; ForwardAgent = false;
} }
(lib.mkIf cfg.certificates.enable { inherit certificateFile; }) (lib.mkIf cfg.certificates.enable { CertificateFile = certificateFile; })
]; ];
} }
(lib.mkIf cfg.matchSets.appdaemon { (lib.mkIf cfg.matchSets.appdaemon {
"appdaemon" = { "appdaemon" = {
hostname = "192.168.1.242"; HostName = "192.168.1.242";
user = "appdaemon"; User = "appdaemon";
}; };
"ad-nix" = { "ad-nix" = {
hostname = "192.168.1.201"; HostName = "192.168.1.201";
user = "appdaemon"; User = "appdaemon";
}; };
}) })
(lib.mkIf cfg.matchSets.certs { (lib.mkIf cfg.matchSets.certs {
"janus" = { "janus" = {
hostname = "janus.john-stream.com"; HostName = "janus.john-stream.com";
user = "root"; User = "root";
}; };
"soteria" = { "soteria" = {
hostname = "soteria.john-stream.com"; HostName = "soteria.john-stream.com";
user = "john"; User = "john";
}; };
}) })
(lib.mkIf cfg.matchSets.homelab { (lib.mkIf cfg.matchSets.homelab {
"docs" = { "docs" = {
hostname = "192.168.1.110"; HostName = "192.168.1.110";
user = "root"; User = "root";
extraOptions = {
RequestTTY = "force"; RequestTTY = "force";
RemoteCommand = "~/.nix-profile/bin/jsl-zsh"; RemoteCommand = "~/.nix-profile/bin/jsl-zsh";
}; };
};
"gitea" = { "gitea" = {
hostname = "192.168.1.104"; HostName = "192.168.1.104";
user = "john"; User = "john";
}; };
"hermes" = { "hermes" = {
hostname = "192.168.1.150"; HostName = "192.168.1.150";
user = "root"; User = "root";
# Enabling this breaks the ability of Zed to install its remote stuff # Enabling this breaks the ability of Zed to install its remote stuff
# extraOptions = {
# RequestTTY = "force"; # RequestTTY = "force";
# RemoteCommand = "/root/.nix-profile/bin/jsl-zsh"; # RemoteCommand = "/root/.nix-profile/bin/jsl-zsh";
# };
}; };
"panoptes" = { "panoptes" = {
hostname = "192.168.1.107"; HostName = "192.168.1.107";
user = "panoptes"; User = "panoptes";
}; };
}) })
(lib.mkIf cfg.matchSets.dev { (lib.mkIf cfg.matchSets.dev {
"test-nix" = { "test-nix" = {
hostname = "fded:fb16:653e:25da:be24:11ff:fea0:753f"; HostName = "fded:fb16:653e:25da:be24:11ff:fea0:753f";
user = "john"; User = "john";
extraOptions = {
RequestTTY = "auto"; RequestTTY = "auto";
# RemoteCommand = "/run/current-system/sw/bin/jsl-zsh"; # RemoteCommand = "/run/current-system/sw/bin/jsl-zsh";
}; };
};
}) })
(lib.mkIf cfg.matchSets.tailscale { (lib.mkIf cfg.matchSets.tailscale {
"jdl-docker" = { "jdl-docker" = {
hostname = "jdl-docker.tailcf205.ts.net"; HostName = "jdl-docker.tailcf205.ts.net";
user = "john"; User = "john";
extraOptions = {
RequestTTY = "auto"; RequestTTY = "auto";
# RemoteCommand = "~/.nix-profile/bin/jsl-zsh"; # RemoteCommand = "~/.nix-profile/bin/jsl-zsh";
}; };
};
}) })
]; ];
}; };