We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 08c999d commit 7c259ceCopy full SHA for 7c259ce
1 file changed
stack.sh
@@ -169,9 +169,13 @@ LIBVIRT_TYPE=${LIBVIRT_TYPE:-kvm}
169
# cases unless you are working on multi-zone mode.
170
SCHEDULER=${SCHEDULER:-nova.scheduler.simple.SimpleScheduler}
171
172
-# Use the first IP unless an explicit is set by ``HOST_IP`` environment variable
+# Use the eth0 IP unless an explicit is set by ``HOST_IP`` environment variable
173
if [ ! -n "$HOST_IP" ]; then
174
- HOST_IP=`LC_ALL=C /sbin/ifconfig | grep -m 1 'inet addr:'| cut -d: -f2 | awk '{print $1}'`
+ HOST_IP=`LC_ALL=C /sbin/ifconfig eth0 | grep -m 1 'inet addr:'| cut -d: -f2 | awk '{print $1}'`
175
+ if [ "$HOST_IP" = "" ];
176
+ echo "Could not determine host ip address. Please specify HOST_IP in your localrc."
177
+ exit 1
178
+ fi
179
fi
180
181
# Service startup timeout
0 commit comments