Files
rustfs/scripts/probe.sh
JimChenWYU 18dd4db147 POSIX Shell
2024-09-24 15:12:16 +08:00

16 lines
210 B
Bash

#!/bin/sh
# Please use POSIX Shell
# https://www.grymoire.com/Unix/Sh.html
IP=127.0.0.1
PORT=9000
while true; do
nc -zv ${IP} ${PORT}
if [ "$?" -eq "0" ]; then
exit 0
fi
sleep 2
done