Commit 5a3c2d80 authored by Marcin Owsiany's avatar Marcin Owsiany

Limit number of pods listed as master liveness check.

parent 64ed037e
...@@ -1532,7 +1532,7 @@ function check-cluster() { ...@@ -1532,7 +1532,7 @@ function check-cluster() {
-H "Authorization: Bearer ${KUBE_BEARER_TOKEN}" \ -H "Authorization: Bearer ${KUBE_BEARER_TOKEN}" \
${secure} \ ${secure} \
--max-time 5 --fail \ --max-time 5 --fail \
"https://${KUBE_MASTER_IP}/api/v1/pods" > "${curl_out}" 2>&1; do "https://${KUBE_MASTER_IP}/api/v1/pods?limit=100" > "${curl_out}" 2>&1; do
local elapsed=$(($(date +%s) - ${start_time})) local elapsed=$(($(date +%s) - ${start_time}))
if [[ ${elapsed} -gt ${KUBE_CLUSTER_INITIALIZATION_TIMEOUT} ]]; then if [[ ${elapsed} -gt ${KUBE_CLUSTER_INITIALIZATION_TIMEOUT} ]]; then
echo -e "${color_red}Cluster failed to initialize within ${KUBE_CLUSTER_INITIALIZATION_TIMEOUT} seconds.${color_norm}" >&2 echo -e "${color_red}Cluster failed to initialize within ${KUBE_CLUSTER_INITIALIZATION_TIMEOUT} seconds.${color_norm}" >&2
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment