Skip to content

Commit c067263

Browse files
authored
improve wait condition (#686)
1 parent a593d4b commit c067263

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

docs/modules/hive/examples/getting_started/getting_started.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ then
2020
exit 1
2121
fi
2222

23+
echo "Waiting for node(s) to be ready..."
24+
kubectl wait node --all --for=condition=Ready --timeout=120s
25+
2326
cd "$(dirname "$0")"
2427

2528
case "$1" in
@@ -93,6 +96,9 @@ exit 1
9396
;;
9497
esac
9598

99+
# TODO: Remove once https://github.com/stackabletech/issues/issues/828 has been implemented (see that issue for details).
100+
until kubectl get crd hiveclusters.hive.stackable.tech >/dev/null 2>&1; do echo "Waiting for CRDs to be installed" && sleep 1; done
101+
96102
echo "Install HiveCluster"
97103
# tag::install-hive[]
98104
kubectl apply -f hive-minio-credentials.yaml

docs/modules/hive/examples/getting_started/getting_started.sh.j2

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ then
2020
exit 1
2121
fi
2222

23+
echo "Waiting for node(s) to be ready..."
24+
kubectl wait node --all --for=condition=Ready --timeout=120s
25+
2326
cd "$(dirname "$0")"
2427

2528
case "$1" in
@@ -93,6 +96,9 @@ exit 1
9396
;;
9497
esac
9598

99+
# TODO: Remove once https://github.com/stackabletech/issues/issues/828 has been implemented (see that issue for details).
100+
until kubectl get crd hiveclusters.hive.stackable.tech >/dev/null 2>&1; do echo "Waiting for CRDs to be installed" && sleep 1; done
101+
96102
echo "Install HiveCluster"
97103
# tag::install-hive[]
98104
kubectl apply -f hive-minio-credentials.yaml

0 commit comments

Comments
 (0)