Improve help text for floating ips options.

The previous commit moved the config options in network/floating_ips.py
to a central location. This commit adds additional
help text to those options.

Also, improved help text based on [1] and removed the tags.

  [1] https://wiki.openstack.org/wiki/ConfigOptionsConsistency

Blueprint centralize-config-options-newton

Change-Id: Ia22d79a3597ec6b641f23571e392dd1a4ca0f20f
This commit is contained in:
Sujitha 2016-05-18 19:36:39 +00:00 committed by John Garbutt
parent da55da00b5
commit c7242b6a6c

View File

@ -1,9 +1,4 @@
# needs:fix_opt_description # needs:fix_opt_description
# needs:check_deprecation_status
# needs:check_opt_group_and_type
# needs:fix_opt_description_indentation
# needs:fix_opt_registration_consistency
# Copyright 2016 Huawei Technology corp. # Copyright 2016 Huawei Technology corp.
# All Rights Reserved. # All Rights Reserved.
@ -22,41 +17,81 @@
from oslo_config import cfg from oslo_config import cfg
default_floating_pool_opt = cfg.StrOpt('default_floating_pool',
# TODO(johngarbutt) all of these opitions only work with nova-network.
# We need to find a good way to document that.
floating_ip_opts = [
cfg.StrOpt('default_floating_pool',
default='nova', default='nova',
help='Default pool for floating IPs') help="""
Default pool for floating IPs.
auto_assign_opt = cfg.BoolOpt('auto_assign_floating_ip', This option specifies the default floating IP pool for allocating floating IPs.
While allocating a floating ip, users can optionally pass in the name of the
pool they want to allocate from, otherwise it will be pulled from the
default pool.
If this option is not set, then 'nova' is used as default floating pool.
Possible values:
* Any string representing a floating IP pool name
"""),
cfg.BoolOpt('auto_assign_floating_ip',
default=False, default=False,
help='Autoassigning floating IP to VM') help="""
Autoassigning floating IP to VM
dns_mgr_opt = cfg.StrOpt('floating_ip_dns_manager', When set to True, floating IP is auto allocated and associated
to the VM upon creation.
"""),
cfg.StrOpt('floating_ip_dns_manager',
default='nova.network.noop_dns_driver.NoopDNSDriver', default='nova.network.noop_dns_driver.NoopDNSDriver',
help='Full class name for the DNS Manager for ' help="""
'floating IPs') Full class name for the DNS Manager for floating IPs.
instance_dns_opt = cfg.StrOpt('instance_dns_manager', This option specifies the class of the driver that provides functionality
to manage DNS entries associated with floating IPs.
When a user adds a DNS entry for a specified domain to a floating IP,
nova will add a DNS entry using the specified floating DNS driver.
When a floating IP is deallocated, its DNS entry will automatically be deleted.
Possible values:
* Full Python path to the class to be used
"""),
cfg.StrOpt('instance_dns_manager',
default='nova.network.noop_dns_driver.NoopDNSDriver', default='nova.network.noop_dns_driver.NoopDNSDriver',
help='Full class name for the DNS Manager for ' help="""
'instance IPs') Full class name for the DNS Manager for instance IPs.
dns_domain_opt = cfg.StrOpt('instance_dns_domain', This option specifies the class of the driver that provides functionality
to manage DNS entries for instances.
On instance creation, nova will add DNS entries for the instance name and
id, using the specified instance DNS driver and domain. On instance deletion,
nova will remove the DNS entries.
Possible values:
* Full Python path to the class to be used
"""),
# TODO(aunnam): remove default
cfg.StrOpt('instance_dns_domain',
default='', default='',
help='Full class name for the DNS Zone ' help="""
'for instance IPs') If specified, Nova checks if the availability_zone of every instance matches
what the database says the availability_zone should be for the specified
ALL_OPTS = [ dns_domain.
default_floating_pool_opt, """)
auto_assign_opt,
dns_domain_opt,
dns_mgr_opt,
instance_dns_opt
] ]
def register_opts(conf): def register_opts(conf):
conf.register_opts(ALL_OPTS) conf.register_opts(floating_ip_opts)
def list_opts(): def list_opts():
return {'DEFAULT': ALL_OPTS} return {'DEFAULT': floating_ip_opts}