File tree Expand file tree Collapse file tree 3 files changed +8
-28
lines changed Expand file tree Collapse file tree 3 files changed +8
-28
lines changed Original file line number Diff line number Diff line change @@ -780,14 +780,19 @@ deploy_chaos_mesh() {
780
780
781
781
helm repo add chaos-mesh https://charts.chaos-mesh.org
782
782
if [ -n " ${MINIKUBE} " ]; then
783
- helm install chaos-mesh chaos-mesh/chaos-mesh --namespace=${NAMESPACE} --set chaosDaemon.runtime=docker --set dashboard.create=false --version ${CHAOS_MESH_VER}
783
+ helm install chaos-mesh chaos-mesh/chaos-mesh --namespace=${NAMESPACE} --set chaosDaemon.runtime=docker --set dashboard.create=false --version ${CHAOS_MESH_VER} --wait
784
784
else
785
- helm install chaos-mesh chaos-mesh/chaos-mesh --namespace=${NAMESPACE} --set chaosDaemon.runtime=containerd --set chaosDaemon.socketPath=/run/containerd/containerd.sock --set dashboard.create=false --version ${CHAOS_MESH_VER}
785
+ helm install chaos-mesh chaos-mesh/chaos-mesh --namespace=${NAMESPACE} --set chaosDaemon.runtime=containerd --set chaosDaemon.socketPath=/run/containerd/containerd.sock --set dashboard.create=false --version ${CHAOS_MESH_VER} --wait
786
786
fi
787
787
if [[ -n $OPENSHIFT ]]; then
788
788
oc adm policy add-scc-to-user privileged -z chaos-daemon --namespace=${NAMESPACE}
789
789
fi
790
- sleep 10
790
+
791
+ echo " Waiting for chaos-mesh DaemonSet to be ready..."
792
+ until [ " $( kubectl get daemonset chaos-daemon -n ${NAMESPACE} -o jsonpath=' {.status.numberReady}' ) " = " $( kubectl get daemonset chaos-daemon -n ${NAMESPACE} -o jsonpath=' {.status.desiredNumberScheduled}' ) " ]; do
793
+ echo " Waiting for DaemonSet chaos-daemon..."
794
+ sleep 5
795
+ done
791
796
}
792
797
793
798
destroy_chaos_mesh () {
Original file line number Diff line number Diff line change @@ -13,16 +13,3 @@ status:
13
13
readyReplicas : 3
14
14
replicas : 3
15
15
updatedReplicas : 3
16
- ---
17
- apiVersion : apps/v1
18
- kind : DaemonSet
19
- metadata :
20
- name : chaos-daemon
21
- status :
22
- currentNumberScheduled : 3
23
- desiredNumberScheduled : 3
24
- numberAvailable : 3
25
- numberMisscheduled : 0
26
- numberReady : 3
27
- observedGeneration : 1
28
- updatedNumberScheduled : 3
Original file line number Diff line number Diff line change @@ -59,15 +59,3 @@ status:
59
59
state : ready
60
60
state : ready
61
61
---
62
- apiVersion : apps/v1
63
- kind : DaemonSet
64
- metadata :
65
- name : chaos-daemon
66
- status :
67
- currentNumberScheduled : 3
68
- desiredNumberScheduled : 3
69
- numberAvailable : 3
70
- numberMisscheduled : 0
71
- numberReady : 3
72
- observedGeneration : 1
73
- updatedNumberScheduled : 3
You can’t perform that action at this time.
0 commit comments