Add basic SSH config
This commit is contained in:
parent
b5b19b6f2a
commit
f6a41038ed
2 changed files with 66 additions and 0 deletions
64
config/ssh.nix
Normal file
64
config/ssh.nix
Normal file
|
@ -0,0 +1,64 @@
|
|||
{
|
||||
programs.ssh = {
|
||||
enable = true;
|
||||
|
||||
forwardAgent = false;
|
||||
compression = false;
|
||||
hashKnownHosts = true;
|
||||
serverAliveInterval = 60;
|
||||
extraConfig = ''
|
||||
IgnoreUnknown UseKeychain,AddKeysToAgent
|
||||
UseKeychain yes
|
||||
AddKeysToAgent yes
|
||||
UpdateHostKeys ask
|
||||
VerifyHostKeyDNS yes
|
||||
'';
|
||||
|
||||
matchBlocks = {
|
||||
# Work
|
||||
|
||||
"git.app.nedeco.de" = {
|
||||
port = 22;
|
||||
user = "git";
|
||||
identitiesOnly = true;
|
||||
identityFile = "~/.ssh/nedeco_gitlab";
|
||||
compression = true;
|
||||
};
|
||||
|
||||
"nedeco-smartos-hosting" = {
|
||||
host = "10.0.90.*";
|
||||
port = 22;
|
||||
user = "root";
|
||||
identitiesOnly = true;
|
||||
identityFile = "~/.ssh/nedeco";
|
||||
};
|
||||
|
||||
# Private
|
||||
|
||||
"github.com" = {
|
||||
port = 22;
|
||||
user = "git";
|
||||
identitiesOnly = true;
|
||||
identityFile = "~/.ssh/GitHub";
|
||||
compression = true;
|
||||
};
|
||||
|
||||
"gitlab.com" = {
|
||||
port = 22;
|
||||
user = "git";
|
||||
identitiesOnly = true;
|
||||
identityFile = "~/.ssh/GitLab";
|
||||
compression = true;
|
||||
};
|
||||
|
||||
"nas" = {
|
||||
host = "10.0.0.100";
|
||||
port = 22;
|
||||
user = "daniel";
|
||||
identitiesOnly = true;
|
||||
identityFile = "~/.ssh/freenas";
|
||||
compression = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
2
home.nix
2
home.nix
|
@ -18,6 +18,8 @@
|
|||
|
||||
./programs/scripts.nix
|
||||
|
||||
./config/ssh.nix
|
||||
|
||||
./config/yt-dlp.nix
|
||||
];
|
||||
|
||||
|
|
Loading…
Reference in a new issue