2025-11-04 22:28:28 -08:00
|
|
|
{ ... }:
|
|
|
|
|
{
|
|
|
|
|
programs.ssh = {
|
|
|
|
|
enable = true;
|
|
|
|
|
|
2025-12-20 08:16:47 -08:00
|
|
|
enableDefaultConfig = false;
|
|
|
|
|
|
2025-11-04 22:28:28 -08:00
|
|
|
matchBlocks = let
|
|
|
|
|
tb1 = "~/.ssh/id_rsa.tb1.pub";
|
|
|
|
|
tb2 = "~/.ssh/id_rsa.tb2.pub";
|
|
|
|
|
in
|
|
|
|
|
{
|
2025-12-20 08:16:47 -08:00
|
|
|
# Defaults
|
|
|
|
|
"*" = {
|
|
|
|
|
# Configure sharing of multiple sessions over a single network connection.
|
|
|
|
|
controlMaster = "auto";
|
|
|
|
|
# Specify path to the control socket used for connection sharing.
|
|
|
|
|
controlPath = "~/.ssh/master-%r@%n:%p";
|
|
|
|
|
# Whether control socket should remain open in the background.
|
|
|
|
|
controlPersist = "10m";
|
|
|
|
|
|
|
|
|
|
# Set default timeout in seconds after which response will be requested.
|
|
|
|
|
serverAliveInterval = 15;
|
|
|
|
|
|
|
|
|
|
# Whether the connection to the authentication agent (if any) will be forwarded to
|
|
|
|
|
# the remote machine.
|
|
|
|
|
forwardAgent = false;
|
|
|
|
|
};
|
|
|
|
|
|
2025-11-04 22:28:28 -08:00
|
|
|
# HomeLab Machines
|
|
|
|
|
"fs1" = {
|
|
|
|
|
hostname = "fs1.t1.xyz";
|
|
|
|
|
identityFile = tb1;
|
2025-11-06 08:28:22 -08:00
|
|
|
forwardAgent = true;
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
|
|
|
|
"fs1.local" = {
|
|
|
|
|
hostname = "192.168.50.100";
|
|
|
|
|
identityFile = tb1;
|
2025-11-06 08:28:22 -08:00
|
|
|
forwardAgent = true;
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
"tr1" = {
|
|
|
|
|
hostname = "tr1.t1.xyz";
|
2025-11-05 18:57:59 -08:00
|
|
|
port = 22001;
|
2025-11-04 22:28:28 -08:00
|
|
|
identityFile = tb1;
|
2025-11-06 08:28:22 -08:00
|
|
|
forwardAgent = true;
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
|
|
|
|
"tr1.local" = {
|
|
|
|
|
hostname = "192.168.50.101";
|
|
|
|
|
identityFile = tb1;
|
2025-11-06 08:28:22 -08:00
|
|
|
forwardAgent = true;
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
|
|
|
|
|
2025-11-15 23:59:17 -08:00
|
|
|
"zenwifi" = {
|
|
|
|
|
hostname = "192.168.50.1";
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
};
|
|
|
|
|
|
2025-12-20 08:16:47 -08:00
|
|
|
"teb" = {
|
|
|
|
|
hostname = "teb";
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
forwardAgent = true;
|
|
|
|
|
};
|
|
|
|
|
"fix" = {
|
|
|
|
|
hostname = "fix";
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
forwardAgent = true;
|
|
|
|
|
};
|
|
|
|
|
|
2026-01-09 20:26:57 -08:00
|
|
|
"teb-r" = {
|
|
|
|
|
hostname = "fs1.t1.xyz";
|
|
|
|
|
port = 22003;
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
forwardAgent = true;
|
|
|
|
|
};
|
|
|
|
|
|
2025-11-04 22:28:28 -08:00
|
|
|
# Cloud Machines
|
|
|
|
|
"t1" = {
|
|
|
|
|
hostname = "95.216.215.4";
|
|
|
|
|
identityFile = tb1;
|
2025-11-06 08:28:22 -08:00
|
|
|
forwardAgent = true;
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
|
|
|
|
"oc1" = {
|
|
|
|
|
hostname = "64.181.254.177";
|
|
|
|
|
identityFile = tb1;
|
2025-11-06 08:28:22 -08:00
|
|
|
forwardAgent = true;
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
2026-01-08 05:45:33 -08:00
|
|
|
|
|
|
|
|
# Git Services
|
|
|
|
|
"github.com" = {
|
|
|
|
|
user = "git";
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
};
|
|
|
|
|
"bitbucket.org" = {
|
|
|
|
|
user = "git";
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
};
|
|
|
|
|
"gitlab.com" = {
|
|
|
|
|
user = "git";
|
|
|
|
|
identityFile = tb1;
|
|
|
|
|
};
|
2025-11-04 22:28:28 -08:00
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|