summaryrefslogtreecommitdiffstats
path: root/ci/util.sh
diff options
context:
space:
mode:
authorDaniel Balsiger <Daniel.Balsiger@swisscom.com>2018-11-02 23:00:46 +0100
committerTim Rozet <trozet@redhat.com>2018-11-20 03:59:28 +0000
commit705e95b6d90a632c11ad4a2b488d56ca87f59a6f (patch)
tree899901567fcc9a8fd601b199a675f08380c8f0f9 /ci/util.sh
parentde387870dfc45fa9a9b066bbfe1c96c731cb086b (diff)
Make util support more than 10 compute nodes
JIRA: APEX-644 The grep command used in the original code matches multiple nodes when deploying 10+ compute nodes. This makes opnfv-util fail to connect to those nodes. Proposed fix is to grep for "$node " instead. Change-Id: I952664f6f3cab3a98681684cd354513bb3c0ab12 Signed-off-by: Daniel Balsiger <Daniel.Balsiger@swisscom.com> (cherry picked from commit 859fb4703b3f0359e80b35aaa62a94e752707bae)
Diffstat (limited to 'ci/util.sh')
-rwxr-xr-xci/util.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/ci/util.sh b/ci/util.sh
index a9df0213..5172ae1b 100755
--- a/ci/util.sh
+++ b/ci/util.sh
@@ -48,7 +48,7 @@ controller<number> or compute<number>"
node_output=$(undercloud_connect "stack" "source stackrc; nova list")
node=$(echo "$1" | sed -E 's/([a-zA-Z]+)([0-9]+)/\1-\2/')
- node_ip=$(echo "$node_output" | grep "$node" | grep -Eo "[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+")
+ node_ip=$(echo "$node_output" | grep "$node " | grep -Eo "[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+")
if [ "$node_ip" == "" ]; then
echo -e "Unable to find IP for ${node} in \n${node_output}"