File tree 2 files changed +24
-28
lines changed
2 files changed +24
-28
lines changed Original file line number Diff line number Diff line change @@ -118,6 +118,30 @@ no_of_workers="${NO_OF_WORKERS}" \
118
118
enable_nmon=" ${ENABLE_NMON} " \
119
119
envsubst < " ./k8s/master-deployment.yaml" | kubectl apply -f -
120
120
121
+ # Wait till all pods are running
122
+ cur_timestamp=" $( date +%s) "
123
+ end_timestamp=" $(( cur_timestamp + TIMEOUT_SECONDS)) "
124
+ while true ; do
125
+ if [ " $( date +%s) " -gt " $end_timestamp " ]; then
126
+ echo " Pods are not running"
127
+ exit 1
128
+ fi
129
+
130
+ set +e
131
+ pods_status=" $( kubectl get pods | grep -v ' STATUS' | grep -v ' Running' ) "
132
+ set -e
133
+ if [ -z " $pods_status " ]; then
134
+ echo " All pods are running"
135
+ break
136
+ fi
137
+
138
+ echo " ----------------------------------------"
139
+ echo " Waiting for pods to be running"
140
+ echo " ----------------------------------------"
141
+ echo " $pods_status "
142
+ sleep 5
143
+ done
144
+
121
145
# wait until master starts listening
122
146
cur_timestamp=" $( date +%s) "
123
147
end_timestamp=" $(( cur_timestamp + TIMEOUT_SECONDS)) "
Original file line number Diff line number Diff line change @@ -69,34 +69,6 @@ cp -r env_init env
69
69
cd " $PROJECT_ROOT "
70
70
build_and_run_on_k8s
71
71
72
- # Wait till all pods are running
73
- cur_timestamp=" $( date +%s) "
74
- end_timestamp=" $(( cur_timestamp + TIMEOUT_SECONDS)) "
75
- while true ; do
76
- if [ " $( date +%s) " -gt " $end_timestamp " ]; then
77
- echo " Pods are not running"
78
- echo " Build log:"
79
- cat " $BUILD_LOG "
80
- echo " Run log:"
81
- cat " $RUN_LOG "
82
- force_remove " ${TEST_ROOT} /env"
83
- clear_resources
84
- exit 1
85
- fi
86
-
87
- set +e
88
- pods_status=" $( kubectl get pods | grep -v ' STATUS' | grep -v ' Running' ) "
89
- set -e
90
- if [ -z " $pods_status " ]; then
91
- echo " All pods are running"
92
- break
93
- fi
94
-
95
- echo " Waiting for pods to be running"
96
- echo " $pods_status "
97
- sleep 5
98
- done
99
-
100
72
# Wait till JasmineGraph server start listening
101
73
cur_timestamp=" $( date +%s) "
102
74
end_timestamp=" $(( cur_timestamp + TIMEOUT_SECONDS)) "
You can’t perform that action at this time.
0 commit comments