Remove --nova-net-id option
Support for nova-network was removed from manila during Ocata cycle[1], and nova-network was actually removed from nova several cycles ago. [1] b213a25c44c0d49edefaa17d3a4de7a88c3c2de0 Change-Id: I4e9d4c7459fcae7bee8ff4919b61f22811336423
This commit is contained in:
parent
3103b8c56a
commit
0510ccbd61
@ -453,24 +453,19 @@ class ManilaCLIClient(base.CLIClient):
|
||||
# Share networks
|
||||
|
||||
def create_share_network(self, name=None, description=None,
|
||||
nova_net_id=None, neutron_net_id=None,
|
||||
neutron_subnet_id=None, availability_zone=None,
|
||||
neutron_net_id=None, neutron_subnet_id=None,
|
||||
availability_zone=None,
|
||||
microversion=None):
|
||||
"""Creates share network.
|
||||
|
||||
:param name: text -- desired name of new share network
|
||||
:param description: text -- desired description of new share network
|
||||
:param nova_net_id: text -- ID of Nova network
|
||||
:param neutron_net_id: text -- ID of Neutron network
|
||||
:param neutron_subnet_id: text -- ID of Neutron subnet
|
||||
|
||||
NOTE: 'nova_net_id' and 'neutron_net_id'/'neutron_subnet_id' are
|
||||
mutually exclusive.
|
||||
"""
|
||||
params = self._combine_share_network_data(
|
||||
name=name,
|
||||
description=description,
|
||||
nova_net_id=nova_net_id,
|
||||
neutron_net_id=neutron_net_id,
|
||||
neutron_subnet_id=neutron_subnet_id,
|
||||
availability_zone=availability_zone
|
||||
@ -481,7 +476,7 @@ class ManilaCLIClient(base.CLIClient):
|
||||
return share_network
|
||||
|
||||
def _combine_share_network_data(self, name=None, description=None,
|
||||
nova_net_id=None, neutron_net_id=None,
|
||||
neutron_net_id=None,
|
||||
neutron_subnet_id=None,
|
||||
availability_zone=None):
|
||||
"""Combines params for share network operations 'create' and 'update'.
|
||||
@ -493,8 +488,6 @@ class ManilaCLIClient(base.CLIClient):
|
||||
data['--name'] = name
|
||||
if description is not None:
|
||||
data['--description'] = description
|
||||
if nova_net_id is not None:
|
||||
data['--nova_net_id'] = nova_net_id
|
||||
if neutron_net_id is not None:
|
||||
data['--neutron_net_id'] = neutron_net_id
|
||||
if neutron_subnet_id is not None:
|
||||
@ -516,23 +509,18 @@ class ManilaCLIClient(base.CLIClient):
|
||||
|
||||
@not_found_wrapper
|
||||
def update_share_network(self, share_network, name=None, description=None,
|
||||
nova_net_id=None, neutron_net_id=None,
|
||||
neutron_net_id=None,
|
||||
neutron_subnet_id=None, microversion=None):
|
||||
"""Updates share-network by its name or ID.
|
||||
|
||||
:param name: text -- new name for share network
|
||||
:param description: text -- new description for share network
|
||||
:param nova_net_id: text -- ID of some Nova network
|
||||
:param neutron_net_id: text -- ID of some Neutron network
|
||||
:param neutron_subnet_id: text -- ID of some Neutron subnet
|
||||
|
||||
NOTE: 'nova_net_id' and 'neutron_net_id'/'neutron_subnet_id' are
|
||||
mutually exclusive.
|
||||
"""
|
||||
sn_params = self._combine_share_network_data(
|
||||
name=name,
|
||||
description=description,
|
||||
nova_net_id=nova_net_id,
|
||||
neutron_net_id=neutron_net_id,
|
||||
neutron_subnet_id=neutron_subnet_id)
|
||||
share_network_raw = self.manila(
|
||||
|
@ -3313,15 +3313,6 @@ def do_reset_state(cs, args):
|
||||
|
||||
|
||||
@api_versions.wraps("1.0", "2.25")
|
||||
@cliutils.arg(
|
||||
'--nova-net-id',
|
||||
'--nova-net_id', '--nova_net_id', '--nova_net-id', # aliases
|
||||
metavar='<nova-net-id>',
|
||||
default=None,
|
||||
action='single_alias',
|
||||
help="Nova net ID. Used to set up network for share servers. This "
|
||||
"option is deprecated and will be rejected in newer releases "
|
||||
"of OpenStack Manila.")
|
||||
@cliutils.arg(
|
||||
'--neutron-net-id',
|
||||
'--neutron-net_id', '--neutron_net_id', '--neutron_net-id',
|
||||
@ -3352,7 +3343,6 @@ def do_share_network_create(cs, args):
|
||||
values = {
|
||||
'neutron_net_id': args.neutron_net_id,
|
||||
'neutron_subnet_id': args.neutron_subnet_id,
|
||||
'nova_net_id': args.nova_net_id,
|
||||
'name': args.name,
|
||||
'description': args.description,
|
||||
}
|
||||
@ -3421,15 +3411,6 @@ def do_share_network_create(cs, args): # noqa
|
||||
'share_network',
|
||||
metavar='<share-network>',
|
||||
help='Name or ID of share network to update.')
|
||||
@cliutils.arg(
|
||||
'--nova-net-id',
|
||||
'--nova-net_id', '--nova_net_id', '--nova_net-id', # aliases
|
||||
metavar='<nova-net-id>',
|
||||
default=None,
|
||||
action='single_alias',
|
||||
help="Nova net ID. Used to set up network for share servers. This "
|
||||
"option is deprecated and will be rejected in newer releases "
|
||||
"of OpenStack Manila.")
|
||||
@cliutils.arg(
|
||||
'--neutron-net-id',
|
||||
'--neutron-net_id', '--neutron_net_id', '--neutron_net-id',
|
||||
@ -3460,7 +3441,6 @@ def do_share_network_update(cs, args):
|
||||
values = {
|
||||
'neutron_net_id': args.neutron_net_id,
|
||||
'neutron_subnet_id': args.neutron_subnet_id,
|
||||
'nova_net_id': args.nova_net_id,
|
||||
'name': args.name,
|
||||
'description': args.description,
|
||||
}
|
||||
@ -3574,14 +3554,6 @@ def do_share_network_show(cs, args):
|
||||
action='single_alias',
|
||||
default=None,
|
||||
help='Filter results by attached security service.')
|
||||
@cliutils.arg(
|
||||
'--nova-net-id',
|
||||
'--nova_net_id', '--nova_net-id', '--nova-net_id', # aliases
|
||||
metavar='<nova_net_id>',
|
||||
action='single_alias',
|
||||
default=None,
|
||||
help='Filter results by Nova net ID. This option is deprecated and will '
|
||||
'be rejected in newer releases of OpenStack Manila.')
|
||||
@cliutils.arg(
|
||||
'--neutron-net-id',
|
||||
'--neutron_net_id', '--neutron_net-id', '--neutron-net_id', # aliases
|
||||
@ -3657,7 +3629,6 @@ def do_share_network_list(cs, args):
|
||||
'name': args.name,
|
||||
'created_since': args.created_since,
|
||||
'created_before': args.created_before,
|
||||
'nova_net_id': args.nova_net_id,
|
||||
'neutron_net_id': args.neutron_net_id,
|
||||
'neutron_subnet_id': args.neutron_subnet_id,
|
||||
'network_type': args.network_type,
|
||||
|
@ -0,0 +1,4 @@
|
||||
---
|
||||
upgrade:
|
||||
- |
|
||||
The ``--nova-net-id`` option has been removed from the ``manila`` CLI.
|
Loading…
Reference in New Issue
Block a user