mirror of
https://github.com/duncs/clusterssh.git
synced 2025-04-22 09:22:24 +00:00
Account for multiple ssh host definitions
Account for multiple host definitions within ssh configuration file - see tracker 2888789
This commit is contained in:
parent
d604feee25
commit
b39e649ab3
2 changed files with 4 additions and 1 deletions
|
@ -2,6 +2,8 @@
|
|||
|
||||
* Look for usernames when adding clusters
|
||||
- Thanks to Kristian Lyngstol for the patch
|
||||
* Account for multiple host definitions within ssh configuration file
|
||||
- Thanks to anonymous for the patch
|
||||
|
||||
2009-09-24 Duncan Ferguson <duncan_ferguson@user.sf.net> - v3.27
|
||||
|
||||
|
|
|
@ -433,7 +433,8 @@ sub check_ssh_hostnames {
|
|||
if ( -r $ssh_config && open( SSHCFG, "<", $ssh_config ) ) {
|
||||
while (<SSHCFG>) {
|
||||
next unless (m/^\s*host\s+([\w\.-]+)/i);
|
||||
$ssh_hostnames{$1} = 1;
|
||||
# account for multiple declarations of hosts
|
||||
$ssh_hostnames{$_} = 1 foreach (split(/\s+/, $1) );
|
||||
}
|
||||
close(SSHCFG);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue