Commit 0c3daa2 1 parent 9305f7c commit 0c3daa2 Copy full SHA for 0c3daa2
File tree 2 files changed +6
-2
lines changed
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 1
1
#! /usr/bin/env bash
2
+ # shellcheck disable=all
2
3
# Use this script to test if a given TCP host/port are available
3
4
# https://github.com/vishnubob/wait-for-it
4
5
6
+ # set -euo pipefail
7
+
5
8
WAITFORIT_cmdname=${0##*/ }
6
9
7
10
echoerr () { if [[ $WAITFORIT_QUIET -ne 1 ]]; then echo " $@ " 1>&2 ; fi }
@@ -63,9 +66,9 @@ wait_for_wrapper()
63
66
wait $WAITFORIT_PID
64
67
WAITFORIT_RESULT=$?
65
68
if [[ $WAITFORIT_RESULT -ne 0 ]]; then
66
- echoerr " $WAITFORIT_cmdname : timeout occurred after waiting $WAITFORIT_TIMEOUT seconds for $WAITFORIT_HOST :$WAITFORIT_PORT "
69
+ echoerr " $WAITFORIT_cmdname : timeout occurred after waiting ${ WAITFORIT_TIMEOUT} seconds for $WAITFORIT_HOST :$WAITFORIT_PORT "
67
70
fi
68
- return $WAITFORIT_RESULT
71
+ return ${ WAITFORIT_RESULT}
69
72
}
70
73
71
74
# process arguments
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ SH_SCRIPTS=$(find . -name '*.sh')
6
6
EXIT_STATUS=0
7
7
8
8
for script in ${SH_SCRIPTS} ; do
9
+ [[ ${script} == ' ./.docker/wait-for-it.sh' ]] && continue
9
10
grep ' ^set -euo pipefail' " ${script} " > /dev/null 2>&1 && continue
10
11
11
12
EXIT_STATUS=1
You can’t perform that action at this time.
0 commit comments