4a3a1bd2a2
Add temporary solution in order to support multiple physical networks by mlnx ML2 MechanismDriver. Due to non merged patches in nova that should support propagating physical_network retrieved from port binding:profile attribute to VIF/Network object. The code will be removed once relevant nova patches are merged. The code is disabled by default and should be enabled via ml2_conf_mlnx.ini config file. Change-Id: I815f9e28774efd47bccd1c57481e6ba89075792b Closes-bug: #1291209
33 lines
1.1 KiB
Python
33 lines
1.1 KiB
Python
# Copyright (c) 2014 OpenStack Foundation
|
|
# All Rights Reserved.
|
|
#
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
# you may not use this file except in compliance with the License.
|
|
# You may obtain a copy of the License at
|
|
#
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
#
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
# implied.
|
|
# See the License for the specific language governing permissions and
|
|
# limitations under the License.
|
|
|
|
from oslo.config import cfg
|
|
|
|
from neutron.extensions import portbindings
|
|
|
|
eswitch_opts = [
|
|
cfg.StrOpt('vnic_type',
|
|
default=portbindings.VIF_TYPE_MLNX_DIRECT,
|
|
help=_("Type of VM network interface: mlnx_direct or "
|
|
"hostdev")),
|
|
cfg.BoolOpt('apply_profile_patch',
|
|
default=False,
|
|
help=_("Enable server compatibility with old nova ")),
|
|
]
|
|
|
|
|
|
cfg.CONF.register_opts(eswitch_opts, "ESWITCH")
|