Merge "handle nova servers with spaces in the name"

This commit is contained in:
Jenkins 2016-09-17 02:56:18 +00:00 committed by Gerrit Code Review
commit 678d948361
1 changed files with 4 additions and 1 deletions

View File

@ -5,8 +5,11 @@
#
# Author: Mike Dorman <mdorman@godaddy.com>
IFS="
"
for i in `nova list --all-tenants | grep -v '^+-' | grep -v '^| ID' |\
awk '{print $2 "," $4 "," $6;}'`; do
cut -d "|" -f 2,3,5 | sed -e "s/ *| */,/g" -e "s/^ *//g"` ; do
ID=`echo $i | cut -d, -f 1`
NAME=`echo $i | cut -d, -f 2`
STATUS=`echo $i | cut -d, -f 3`