13 lines
180 B
Text
13 lines
180 B
Text
|
#!/bin/sh
|
||
|
|
||
|
if [ $# -ne 2 ]; then
|
||
|
echo "Usage: $0 <hostname> <port>" >&2
|
||
|
exit 1
|
||
|
fi
|
||
|
|
||
|
while ! nc -z "$1" "$2"; do
|
||
|
echo "$1:$2 not yet available, waiting"
|
||
|
sleep 1
|
||
|
done
|
||
|
echo "Done"
|