Ssh : Move config to nix.

This commit is contained in:
Dmitry Voronin 2024-02-24 23:26:20 +03:00
parent e078b40ca4
commit ed94fcc550
4 changed files with 49 additions and 47 deletions

View file

@ -31,6 +31,7 @@
./module/common/Nvim.nix
./module/common/Package.nix
./module/common/Root.nix
./module/common/Ssh.nix
./module/common/Sshd.nix
./module/common/Swap.nix
./module/common/Tmux.nix

View file

@ -0,0 +1,48 @@
{ ... }: {
programs.ssh.extraConfig = ''
Host dasha
HostName 192.168.1.7
User root
Port 22143
Host desktop
Hostname 192.168.1.3
User root
Port 22143
Host fmpmaven
Hostname 10.30.22.10
User root
Port 22
Host fsight
Hostname 10.30.217.25
User root
Port 22143
Host home
HostName 192.168.1.2
User root
Port 22143
Host laptop
Hostname 192.168.1.9
User root
Port 22143
Host pi
Hostname 192.168.1.6
User root
Port 22143
Host vpn
Hostname 194.113.233.38
User root
Port 22143
Host work
Hostname 192.168.1.5
User root
Port 22143
'';
}

3
.gitignore vendored
View file

@ -101,9 +101,6 @@
!/.ssh/
/.ssh/**
# Ssh config.
!/.ssh/config
# Local configs.
!/.local/
/.local/*

View file

@ -1,44 +0,0 @@
Host dasha
HostName 192.168.1.7
User root
Port 22143
Host desktop
Hostname 192.168.1.3
User root
Port 22143
Host fmpmaven
Hostname 10.30.22.10
User root
Port 22
Host fsight
Hostname 10.30.217.25
User root
Port 22143
Host home
HostName 192.168.1.2
User root
Port 22143
Host laptop
Hostname 192.168.1.9
User root
Port 22143
Host pi
Hostname 192.168.1.6
User root
Port 22143
Host vpn
Hostname 194.113.233.38
User root
Port 22143
Host work
Hostname 192.168.1.5
User root
Port 22143