- Simplify server aliases and add tailscale‑specific aliases - Make SSH module accept a username argument - Add match block for Tailscale host with port 22 and identity file
21 lines
490 B
Nix
21 lines
490 B
Nix
{username, ...}: {
|
|
programs.ssh = {
|
|
enable = true;
|
|
enableDefaultConfig = false;
|
|
matchBlocks = {
|
|
"hp-t640-homeserver" = {
|
|
hostname = "192.168.1.156";
|
|
user = "${username}";
|
|
port = 22;
|
|
identityFile = "~/.ssh/hp-t640-homeserver";
|
|
};
|
|
"hp-t640-homeserver-tailscale" = {
|
|
hostname = "100.106.225.106";
|
|
user = "${username}";
|
|
port = 22;
|
|
identityFile = "~/.ssh/hp-t640-homeserver";
|
|
};
|
|
};
|
|
};
|
|
}
|