From 6b3dc1d41c47b5684a3315b89f98ea4abbc8d474 Mon Sep 17 00:00:00 2001 From: Joshua Olson <joshua.olson.490@gmail.com> Date: Fri, 12 Oct 2018 12:02:50 -0500 Subject: [PATCH] Add some commands to ensure kube-prometheus is fully successfully deployed. --- README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 36aea2cb..bd8b587d 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,12 @@ Though for a quickstart a compiled version of the Kubernetes [manifests](manifes * Simply create the stack: ``` $ kubectl create -f manifests/ || true -$ kubectl create -f manifests/ 2>/dev/null || true # This command sometimes may need to be done twice + +# It can take a few seconds for the above 'create manifests' command to fully create the following resources, so verify the resources are ready before proceeding. +until kubectl get customresourcedefinitions servicemonitors.monitoring.coreos.com ; do date; sleep 1; echo ""; done +until kubectl get servicemonitors --all-namespaces ; do date; sleep 1; echo ""; done + +$ kubectl create -f manifests/ 2>/dev/null || true # This command sometimes may need to be done twice (to workaround a race condition). ``` * And to teardown the stack: ``` -- GitLab