diff options
Diffstat (limited to 'debvm-waitssh')
-rwxr-xr-x | debvm-waitssh | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/debvm-waitssh b/debvm-waitssh index a35c783..32db862 100755 --- a/debvm-waitssh +++ b/debvm-waitssh @@ -14,7 +14,8 @@ B<debvm-waitssh> [B<-q>] [B<-t> I<timeout>] [I<hostname>:]I<port> =head1 DESCRIPTION B<debvm-waitssh> can be used to wait for a virtual machine with exposed ssh port to be reachable on that port. -If no hostname is given, B<127.0.0.1> is assumed. +If no hostname is given, B<127.0.0.1> is assumed. No authentication is attempted by B<debvm-waitssh>, so neither +a username nor a key have to be supplied. =head1 OPTIONS @@ -142,6 +143,14 @@ case "$1" in ;; esac +case "$HOST" in *@*) + if [ "$VERBOSITY" -ge 1 ]; then + echo "$0: hostname '$HOST' must not contain the '@' character. No username is required." >&2 + fi + exit 1 + ;; +esac + # Guard against strings containing anything but digits, strings starting with # zero and empty strings as the port number. # |