Commit 5487a3f8 authored by Jeff Grafton's avatar Jeff Grafton

Fix detect-node-names to not error out if there are no nodes

parent 3b09c641
...@@ -284,12 +284,9 @@ function detect-node-names { ...@@ -284,12 +284,9 @@ function detect-node-names {
"${group}" --zone "${ZONE}" --project "${PROJECT}" \ "${group}" --zone "${ZONE}" --project "${PROJECT}" \
--format='value(instance)')) --format='value(instance)'))
done done
echo "INSTANCE_GROUPS=${INSTANCE_GROUPS[*]}" >&2
echo "NODE_NAMES=${NODE_NAMES[*]}" >&2
else
echo "INSTANCE_GROUPS=" >&2
echo "NODE_NAMES=" >&2
fi fi
echo "INSTANCE_GROUPS=${INSTANCE_GROUPS[*]:-}" >&2
echo "NODE_NAMES=${NODE_NAMES[*]:-}" >&2
} }
# Detect the information about the minions # Detect the information about the minions
......
...@@ -251,7 +251,7 @@ function detect-node-names { ...@@ -251,7 +251,7 @@ function detect-node-names {
"${NODE_INSTANCE_GROUP}" --zone "${ZONE}" --project "${PROJECT}" \ "${NODE_INSTANCE_GROUP}" --zone "${ZONE}" --project "${PROJECT}" \
--format='value(instance)')) --format='value(instance)'))
echo "NODE_NAMES=${NODE_NAMES[*]}" echo "NODE_NAMES=${NODE_NAMES[*]:-}"
} }
# Detect instance group name generated by gke. # Detect instance group name generated by gke.
......
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