diff --git a/scripts/update-ssh-client-config b/scripts/update-ssh-client-config index 0c2f7fd..dc86661 100755 --- a/scripts/update-ssh-client-config +++ b/scripts/update-ssh-client-config @@ -12,10 +12,20 @@ BW_TABLE_STYLE=grep bw nodes -a hostname -- "lambda:not node.dummy" | \ while read node addr do + if [[ -z "$BW_SSH_HOOK_EXTRA_LINE" ]] + then + echo "Host $addr" >>"$tmpfile" + echo "$BW_SSH_HOOK_EXTRA_LINE" >>"$tmpfile" + echo "" >>"$tmpfile" + fi echo "Host $node" >>"$tmpfile" echo "HostName $addr" >>"$tmpfile" + if [[ -z "$BW_SSH_HOOK_EXTRA_LINE" ]] + then + echo "$BW_SSH_HOOK_EXTRA_LINE" >>"$tmpfile" + fi echo "" >>"$tmpfile" done - mv "$tmpfile" ~/.ssh/bwnodes + mv "$tmpfile" ~/.ssh/config.d/bwnodes ) &