User Tools

Site Tools


add_ssh_key_to_multiple_host

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

add_ssh_key_to_multiple_host [2010/09/21 17:43]
k2patel created
add_ssh_key_to_multiple_host [2010/09/21 22:20] (current)
k2patel
Line 25: Line 25:
  echo "Key Successfully Adde"  echo "Key Successfully Adde"
  scp /tmp/$file ${hostlist[${i}]}:​.ssh/​authorized_keys  scp /tmp/$file ${hostlist[${i}]}:​.ssh/​authorized_keys
 +                                rm -rf /tmp/$file
  else  else
- echo "​Failed to add key for host \"​${hostlist[${i}]}\"​ Check manually."​+ echo "​Failed to add key for host \"​${hostlist[${i}]}\"​ Check manually.\n" 
 +                                echo "Local File \"/​tmp/​$file\" ​"
  fi  fi
  fi  fi
add_ssh_key_to_multiple_host.txt · Last modified: 2010/09/21 22:20 by k2patel