os_client_config.
OpenStackConfig
(config_files=None, vendor_files=None, override_defaults=None, force_ipv4=None, envvar_prefix=None, secure_files=None, pw_func=None, session_constructor=None, app_name=None, app_version=None, load_yaml_config=True, load_envvars=True, statsd_host=None, statsd_port=None, statsd_prefix=None, influxdb_config=None)¶auth_config_hook
(config)¶Allow examination of config values before loading auth plugin
OpenStackClient will override this to perform additional checks on auth_type.
get_extra_config
(key, defaults=None)¶Fetch an arbitrary extra chunk of config, laying in defaults.
key (string) – name of the config section to fetch
defaults (dict) – (optional) default values to merge under the found config
get_one
(cloud=None, validate=True, argparse=None, **kwargs)¶Retrieve a single CloudRegion and merge additional options
cloud (string) – The name of the configuration to load from clouds.yaml
validate (boolean) – Validate the config. Setting this to False causes no auth plugin to be created. It’s really only useful for testing.
argparse (Namespace) – An argparse Namespace object; allows direct passing in of argparse options to be added to the cloud config. Values of None and ‘’ will be removed.
region_name – Name of the region of the cloud.
kwargs – Additional configuration options
openstack.config.cloud_region.CloudRegion
keystoneauth1.exceptions.MissingRequiredOptions on missing required auth parameters
get_one_cloud
(cloud=None, validate=True, argparse=None, **kwargs)¶Retrieve a single CloudRegion and merge additional options
cloud (string) – The name of the configuration to load from clouds.yaml
validate (boolean) – Validate the config. Setting this to False causes no auth plugin to be created. It’s really only useful for testing.
argparse (Namespace) – An argparse Namespace object; allows direct passing in of argparse options to be added to the cloud config. Values of None and ‘’ will be removed.
region_name – Name of the region of the cloud.
kwargs – Additional configuration options
openstack.config.cloud_region.CloudRegion
keystoneauth1.exceptions.MissingRequiredOptions on missing required auth parameters
get_one_cloud_osc
(cloud=None, validate=True, argparse=None, **kwargs)¶Retrieve a single CloudRegion and merge additional options
cloud (string) – The name of the configuration to load from clouds.yaml
validate (boolean) – Validate the config. Setting this to False causes no auth plugin to be created. It’s really only useful for testing.
argparse (Namespace) – An argparse Namespace object; allows direct passing in of argparse options to be added to the cloud config. Values of None and ‘’ will be removed.
region_name – Name of the region of the cloud.
kwargs – Additional configuration options
keystoneauth1.exceptions.MissingRequiredOptions on missing required auth parameters
magic_fixes
(config)¶Perform the set of magic argument fixups
option_prompt
(config, p_opt)¶Prompt user for option that requires a value
register_argparse_arguments
(parser, argv, service_keys=None)¶Register all of the common argparse options needed.
Given an argparse parser, register the keystoneauth Session arguments, the keystoneauth Auth Plugin Options and os-cloud. Also, peek in the argv to see if all of the auth plugin options should be registered or merely the ones already configured.
argparse.ArgumentParser – parser to attach argparse options to
argv – the arguments provided to the application
service_keys (string) – Service or list of services this argparse should be specialized for, if known. The first item in the list will be used as the default value for service_type (optional)
:raises exceptions.ConfigException if an invalid auth-type is requested
set_one_cloud
(config_file, cloud, set_config=None)¶Set a single cloud configuration.
config_file (string) – The path to the config file to edit. If this file does not exist it will be created.
cloud (string) – The name of the configuration to save to clouds.yaml
set_config (dict) – Configuration options to be set
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.