A lot more automation for ssh.
(And I probably broke something, but we'll see!)
This commit is contained in:
14
ssh/config
14
ssh/config
@ -1,14 +0,0 @@
|
|||||||
CanonicalizeMaxDots 5
|
|
||||||
CanonicalizeHostname yes
|
|
||||||
CanonicalDomains nerdland.org
|
|
||||||
|
|
||||||
Host gitea.* github.com
|
|
||||||
User git
|
|
||||||
|
|
||||||
Host *.nerdland.org *.nerdland.it.cx
|
|
||||||
AddressFamily inet6
|
|
||||||
|
|
||||||
Host *
|
|
||||||
IdentityFile ~/.ssh/id_%L-%h
|
|
||||||
|
|
||||||
# vim: ft=sshconfig
|
|
||||||
8
ssh/epilogue
Normal file
8
ssh/epilogue
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
Host gitea.* github.com gitlab.com *.github.com *.gitlab.com
|
||||||
|
User git
|
||||||
|
|
||||||
|
|
||||||
|
Host *
|
||||||
|
IdentityFile ~/.ssh/id_%L-%h
|
||||||
|
|
||||||
|
# vim: ft=sshconfig
|
||||||
12
ssh/prologue
Normal file
12
ssh/prologue
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
# This scans your resolver and then custom-creates a config file
|
||||||
|
# for your current resolver situation.
|
||||||
|
#
|
||||||
|
# That config uses Canonicalization to emulate what your local resolver
|
||||||
|
# does in these circumstances.
|
||||||
|
Match exec 'rm -f ~/ssh/search | false'
|
||||||
|
|
||||||
|
Match exec 'grep "^search" /etc/resolv.conf ' exec 'grep search /etc/resolv.conf | awk \'{print "Host *\n\tCanonicalDomains "$2"\n\tCanonicalizeHostname yes\n# v""im:ft=sshconfig"}\' > ~/.ssh/search'
|
||||||
|
|
||||||
|
Include ~/.ssh/search
|
||||||
|
|
||||||
|
# vim: ft=sshconfig
|
||||||
Reference in New Issue
Block a user