Files
nix-config/home/base/tui/ssh.nix
T
Ryan Yin fe4923f8cb fix: suppress nixvim nixpkgs.source and ssh matchBlocks deprecation warnings (#262)
Explicitly set programs.nixvim.nixpkgs.source to suppress the follows
    warning, and migrate all programs.ssh.matchBlocks to programs.ssh.settings
    using upstream PascalCase directive names.
2026-06-03 11:23:30 +08:00

42 lines
863 B
Nix

{
config,
mysecrets,
...
}:
{
home.file.".ssh/romantic.pub".source = "${mysecrets}/public/romantic.pub";
programs.ssh = {
enable = true;
enableDefaultConfig = false;
settings."*" = {
ForwardAgent = false;
AddKeysToAgent = "yes";
Compression = true;
ServerAliveInterval = 0;
ServerAliveCountMax = 3;
HashKnownHosts = false;
UserKnownHostsFile = "~/.ssh/known_hosts";
ControlMaster = "no";
ControlPath = "~/.ssh/master-%r@%n:%p";
ControlPersist = "no";
};
settings = {
"github.com" = {
HostName = "ssh.github.com";
Port = 443;
User = "git";
IdentitiesOnly = true;
};
"192.168.*" = {
ForwardAgent = true;
IdentityFile = "/etc/agenix/ssh-key-romantic";
IdentitiesOnly = true;
};
};
};
}