This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Small function that checks if a TCP port on localhost is open. | |
# | |
# Timeout after 10 attempts. | |
# | |
# Usage: wait_port <port> | |
wait_port() ( | |
local i=0 port=$1 | |
echo "waiting on port $port" | |
# Bash has a magic filesystem that can be used to do basic TCP. | |
# |