File tree Expand file tree Collapse file tree 1 file changed +19
-4
lines changed
Expand file tree Collapse file tree 1 file changed +19
-4
lines changed Original file line number Diff line number Diff line change 1414# License for the specific language governing permissions and limitations
1515# under the License.
1616
17- # This script will run the full functional tests for a given `KUBE_TAG`. It
18- # will download the image, create a cluster, wait for it to hit `CREATE_COMPLETE`
19- # and then run `sonobuoy` against it.
20-
2117source /opt/stack/openrc admin admin
2218
2319OS_DISTRO=${OS_DISTRO:- ubuntu}
@@ -169,6 +165,25 @@ if [[ ${UPGRADE_KUBE_TAG} != ${KUBE_TAG} ]]; then
169165 fi
170166 done
171167
168+ # Wait for kubernetes accessible and Ready.
169+ for i in {1..10}; do
170+ # Get the cluster configuration file
171+ eval $( openstack coe cluster config k8s-cluster)
172+ Node=$( kubectl get node -o wide)
173+ if [[ ${Node} == * " NotReady" * ]]; then
174+ echo " Kubernetes accessible with Not Ready node."
175+ echo " Node status: ${Node} "
176+ sleep 5
177+ elif [[ ${Node} == * " Ready" * ]]; then
178+ echo " Kubernetes accessible with Ready node."
179+ break
180+ else
181+ echo " Currtny retry count: $i "
182+ echo " Node status: ${Node} "
183+ sleep 5
184+ fi
185+ done
186+
172187 # Upgrade cluster
173188 openstack coe cluster upgrade k8s-cluster-upgrade k8s-${UPGRADE_KUBE_TAG}
174189 # Wait for cluster to be "UPDATE_COMPLETE".
You can’t perform that action at this time.
0 commit comments