NSX|V3: ensure that the manager, user and password are set
We need to determine the NSX version used to configure the OVS manager. This requires that these values be set. If they are not set then devstack will not start. Change-Id: I032152b7a2f61e36652acf88d8c727347c090cfb
This commit is contained in:
parent
ac98bf6bfe
commit
da9ee782b9
@ -46,6 +46,9 @@ source $TOP_DIR/lib/neutron_plugins/ovs_base
|
||||
function _version { echo "$@" | awk -F. '{ printf("%d%03d%03d%03d\n", $1,$2,$3,$4); }'; }
|
||||
|
||||
function _ovsdb_connection {
|
||||
die_if_not_set $LINENO NSX_MANAGER "NSX_MANAGER has not been set!"
|
||||
die_if_not_set $LINENO NSX_USER "NSX_USER has not been set!"
|
||||
die_if_not_set $LINENO NSX_PASSWORD "NSX_PASSWORD has not been set!"
|
||||
managers=(${NSX_MANAGER//,/ })
|
||||
NSX_MGR_IP=${managers[0]}
|
||||
NSX_VER=$(curl -s -k -u "$NSX_USER:$NSX_PASSWORD" -H 'Accept: application/json' https://$NSX_MGR_IP/api/v1/node | python -c 'import sys, json; print json.load(sys.stdin)["node_version"][:5]')
|
||||
|
Loading…
x
Reference in New Issue
Block a user