Don't assume nova-manage is present

tools/discover_hosts.sh is run by devstack-gate, and breaks all dsvm job
that doesn't use nova.

nova-manage is perhaps not installed if nova services are not enabled.

This change checks the presence of nova-.

Change-Id: Ic555d241f98d0fa027897c69a7115d1be88f6c96
This commit is contained in:
Mehdi Abaakouk 2017-01-26 11:31:58 +01:00
parent 5713497aa5
commit 5c6aa56e11

View File

@ -15,4 +15,6 @@
# In other words this should be run on the primary
# (API) node in a multi-node setup.
nova-manage cell_v2 discover_hosts --verbose
if [[ -x $(which nova-manage) ]]; then
nova-manage cell_v2 discover_hosts --verbose
fi