LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Mailing Lists

[ILUG] ssh conundrum

[ILUG] ssh conundrum

Niall O Broin niall at linux.ie
Sat Sep 18 13:08:01 IST 2004


I have numerous stanzas like this in ~/.ssh/config :

Host dale
         HostName gateway.mydomain.com
         Port 2204
         HostKeyAlias dale


which makes for convenient use of ssh to access a bunch of machines 
behind the gateway. However, the problem is that when I am connected to 
the LAN behind the gateway this doesn't work (of course it's not 
necessary, but it doesn't work which is the problem). Possible 
solutions are:

1) Maintain 2 different copies of ~/.ssh/config, one without the Host 
stanzas and one with
2) Write a wrapper script for ssh which figures out where I am and does 
the necessary

I don't much like 1) as it necessitates manually switching between 
them. 2) would be OK, and looks like the most likely option. But I'm 
wondering is there a more elegant 3) which might be some extra nifty 
use of ssh config options.



Niall




More information about the ILUG mailing list
Read this without the formatting.
                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell