Merge "TVD: enable DVS to be configured"
This commit is contained in:
commit
c670693cef
@ -63,16 +63,23 @@ function nsxv_configure_service {
|
||||
_nsxv_ini_set use_nsx_policies "$NSXV_USE_NSX_POLICIES"
|
||||
_nsxv_ini_set default_policy_id "$NSXV_DEFAULT_POLICY_ID"
|
||||
_nsxv_ini_set allow_tenant_rules_with_policy "$NSXV_ALLOW_TENANT_RULES_WITH_POLICY"
|
||||
if [[ "$NSXV_USE_DVS_FEATURES" != "" ]]; then
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs host_ip "$VMWAREAPI_IP"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs host_username "$VMWAREAPI_USER"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs host_password "$VMWAREAPI_PASSWORD"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs ca_file "$VMWAREAPI_CA_FILE"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs insecure "$VMWAREAPI_INSECURE"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs dvs_name "$VMWARE_DVS_NAME"
|
||||
}
|
||||
|
||||
function _dvs_ini_set {
|
||||
if [[ $2 != "" ]]; then
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs $1 $2
|
||||
fi
|
||||
}
|
||||
|
||||
function dvs_configure_service {
|
||||
_dvs_ini_set host_ip $1
|
||||
_dvs_ini_set host_username $2
|
||||
_dvs_ini_set host_password $3
|
||||
_dvs_ini_set ca_file $4
|
||||
_dvs_ini_set insecure $5
|
||||
_dvs_ini_set dvs_name $6
|
||||
}
|
||||
|
||||
function _nsxv3_ini_set {
|
||||
if [[ -z $1 || -z $2 ]]; then
|
||||
if [[ $3 != "" ]]; then
|
||||
|
@ -29,6 +29,7 @@ DVS_XTRACE=$(set +o | grep xtrace)
|
||||
set +o xtrace
|
||||
|
||||
source $TOP_DIR/lib/neutron_plugins/ovs_base
|
||||
source $dir/lib/nsx_common
|
||||
|
||||
DVS_BRIDGE=${DVS_BRIDGE:-br-dvs}
|
||||
DVS_INTERFACE=${DVS_INTERFACE:-eth1}
|
||||
@ -95,12 +96,7 @@ function neutron_plugin_configure_plugin_agent {
|
||||
}
|
||||
|
||||
function neutron_plugin_configure_service {
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs host_ip "$VMWAREAPI_IP"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs host_username "$VMWAREAPI_USER"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs host_password "$VMWAREAPI_PASSWORD"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs ca_file "$VMWAREAPI_CA_FILE"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs insecure "$VMWAREAPI_INSECURE"
|
||||
iniset /$Q_PLUGIN_CONF_FILE dvs dvs_name "$VMWARE_DVS_NAME"
|
||||
dvs_configure_service $VMWAREAPI_IP $VMWAREAPI_USER $VMWAREAPI_PASSWORD $VMWAREAPI_CA_FILE $VMWAREAPI_INSECURE $VMWARE_DVS_NAME
|
||||
iniset /$Q_PLUGIN_CONF_FILE DEFAULT nsx_extension_drivers vmware_dvs_dns
|
||||
}
|
||||
|
||||
|
@ -159,6 +159,7 @@ function neutron_plugin_configure_plugin_agent {
|
||||
function neutron_plugin_configure_service {
|
||||
nsxv3_configure_service
|
||||
nsxv_configure_service
|
||||
dvs_configure_service $DVS_VMWAREAPI_IP $DVS_VMWAREAPI_USER $DVS_VMWAREAPI_PASSWORD $DVS_VMWAREAPI_CA_FILE $DVS_VMWAREAPI_INSECURE $VMWARE_DVS_NAME
|
||||
iniset /$Q_PLUGIN_CONF_FILE nsx_tvd nsx_v_extension_drivers vmware_nsxv_dns
|
||||
iniset /$Q_PLUGIN_CONF_FILE nsx_tvd nsx_v3_extension_drivers vmware_nsxv3_dns
|
||||
iniset /$Q_PLUGIN_CONF_FILE nsx_tvd dvs_extension_drivers vmware_dvs_dns
|
||||
|
@ -85,6 +85,9 @@ function neutron_plugin_configure_plugin_agent {
|
||||
function neutron_plugin_configure_service {
|
||||
nsxv_configure_service
|
||||
iniset /$Q_PLUGIN_CONF_FILE DEFAULT nsx_extension_drivers vmware_nsxv_dns
|
||||
if [[ "$NSXV_USE_DVS_FEATURES" != "" ]]; then
|
||||
dvs_configure_service $VMWAREAPI_IP $VMWAREAPI_USER $VMWAREAPI_PASSWORD $VMWAREAPI_CA_FILE $VMWAREAPI_INSECURE $VMWARE_DVS_NAME
|
||||
fi
|
||||
}
|
||||
|
||||
function neutron_plugin_setup_interface_driver {
|
||||
|
Loading…
Reference in New Issue
Block a user