added notification for mising configs
This commit is contained in:
parent
4986bd740b
commit
06c89c1711
@ -200,13 +200,19 @@ function zssh_generate_config4
|
|||||||
then
|
then
|
||||||
sshkey="$zssh_private_keys/$ssh_node.key"
|
sshkey="$zssh_private_keys/$ssh_node.key"
|
||||||
zshlibs_log zssh_client "generating '$dst' with key '$sshkey'"
|
zshlibs_log zssh_client "generating '$dst' with key '$sshkey'"
|
||||||
|
matched=1
|
||||||
rm "$dst" 2> /dev/null
|
rm "$dst" 2> /dev/null
|
||||||
for src in "$srcs"/*.sshconf(N)
|
for src in "$srcs"/*.sshconf(N)
|
||||||
do
|
do
|
||||||
|
matched=0
|
||||||
zshlibs_log zssh_client "sourcing $src"
|
zshlibs_log zssh_client "sourcing $src"
|
||||||
cat "$src" >> "$dst"
|
cat "$src" >> "$dst"
|
||||||
printf "\n IdentityFile %s\n\n" "$sshkey" >> "$dst"
|
printf "\n IdentityFile %s\n\n" "$sshkey" >> "$dst"
|
||||||
done
|
done
|
||||||
|
if ! matched
|
||||||
|
then
|
||||||
|
zshlibs_log zssh_client "no configs for '$dst'"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
zshlibs_log zssh_client "done with $ssh_node"
|
zshlibs_log zssh_client "done with $ssh_node"
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user