Get the names of all the plugins that are available on the system.
This is particularly useful for help and error text to prompt a user for example what plugins they may specify.
Returns: | A list of names. |
---|---|
Return type: | frozenset |
Retrieve all the plugin classes available on the system.
Returns: | A dict with plugin entrypoint name as the key and the plugin loader as the value. |
---|---|
Return type: | dict |
Retrieve a plugin class by its entrypoint name.
Parameters: | name (str) – The name of the object to get. |
---|---|
Returns: | An auth plugin class. |
Return type: | keystoneauth1.loading.BaseLoader |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Get the options for a specific plugin.
This will be the list of options that is registered and loaded by the specified plugin.
Returns: | A list of keystoneauth1.loading.Opt options. |
---|---|
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Bases: object
Return if the plugin is available for loading.
If a plugin is missing dependencies or for some other reason should not be available to the current system it should override this property and return False to exclude itself from the plugin list.
Return type: | bool |
---|
Create a plugin from the options available for the loader.
Given the options that were specified by the loader create an appropriate plugin. You can override this function in your loader.
This used to be specified by providing the plugin_class property and this is still supported, however specifying a property didn’t let you choose a plugin type based upon the options that were presented.
Override this function if you wish to return different plugins based on the options presented, otherwise you can simply provide the plugin_class property.
Added 2.9
Return the list of parameters associated with the auth plugin.
This list may be used to generate CLI or config arguments.
Returns: | A list of Param objects describing available plugin parameters. |
---|---|
Return type: | list |
Create a plugin from the arguments retrieved from get_options.
A client can override this function to do argument validation or to handle differences between the registered options and what is required to create the plugin.
Load a plugin from getter function that returns appropriate values.
To handle cases other than the provided CONF and CLI loading you can specify a custom loader function that will be queried for the option value. The getter is a function that takes a keystoneauth1.loading.Opt and returns a value to load with.
Parameters: | getter (callable) – A function that returns a value for the given opt. |
---|---|
Returns: | An authentication Plugin. |
Return type: | keystoneauth1.plugin.BaseAuthPlugin |
Register CLI options needed to create a plugin.
The function inspects the provided arguments so that it can also register the options required for that specific plugin if available.
Parameters: |
|
---|---|
Returns: | The plugin class that will be loaded or None if not provided. |
Return type: | |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Retrieve the created plugin from the completed argparse results.
Loads and creates the auth plugin from the information parsed from the command line by argparse.
Parameters: | namespace (Namespace) – The result from CLI parsing. |
---|---|
Returns: | An auth plugin, or None if a name is not provided. |
Return type: | keystoneauth1.plugin.BaseAuthPlugin |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Get the oslo_config options common for all auth plugins.
These may be useful without being registered for config file generation or to manipulate the options before registering them yourself.
auth_type: | The name of the plugin to load. |
---|---|
auth_section: | The config file section to load options from. |
Returns: | A list of oslo_config options. |
---|
Get the oslo_config options for a specific plugin.
This will be the list of config options that is registered and loaded by the specified plugin.
Parameters: | plugin (str or keystoneauth1._loading.BaseLoader) – The name of the plugin loader or a plugin loader object |
---|---|
Returns: | A list of oslo_config options. |
Register the oslo_config options that are needed for a plugin.
This only registers the basic options shared by all plugins. Options that are specific to a plugin are loaded just before they are read.
The defined options are:
- auth_type: the name of the auth plugin that will be used for
authentication.
- auth_section: the group from which further auth plugin options should be
taken. If section is not provided then the auth plugin options will be taken from the same group as provided in the parameters.
Parameters: |
|
---|
Load a plugin from an oslo_config CONF object.
Each plugin will register their own required options and so there is no standard list and the plugin should be consulted.
The base options should have been registered with register_conf_options before this function is called.
Parameters: |
|
---|---|
Returns: | An authentication Plugin or None if a name is not provided |
Return type: | |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Bases: keystoneauth1.loading.base.BaseLoader
Base Option handling for identity plugins.
This class defines options and handling that should be common across all plugins that are developed against the OpenStack identity service. It provides the options expected by the keystoneauth1.identity.BaseIdentityPlugin class.
Bases: keystoneauth1.loading.identity.BaseIdentityLoader
Base Option handling for identity plugins.
This class defines options and handling that should be common to the V2 identity API. It provides the options expected by the keystoneauth1.identity.v2.Auth class.
Bases: keystoneauth1.loading.identity.BaseIdentityLoader
Base Option handling for identity plugins.
This class defines options and handling that should be common to the V3 identity API. It provides the options expected by the keystoneauth1.identity.v3.Auth class.
Bases: keystoneauth1.loading.identity.BaseV3Loader
Base Option handling for federation plugins.
This class defines options and handling that should be common to the V3 identity federation API. It provides the options expected by the keystoneauth1.identity.v3.FederationBaseAuth class.
Bases: keystoneauth1.loading.identity.BaseIdentityLoader
Base Option handling for generic plugins.
This class defines options and handling that should be common to generic plugins. These plugins target the OpenStack identity service however are designed to be independent of API version. It provides the options expected by the keystoneauth1.identity.v3.BaseGenericPlugin class.
Bases: object
An option required by an authentication plugin.
Opts provide a means for authentication plugins that are going to be dynamically loaded to specify the parameters that are to be passed to the plugin on initialization.
The Opt specifies information about the way the plugin parameter is to be represented in different loading mechanisms.
When defining an Opt with a - the - should be present in the name parameter. This will automatically be converted to an _ when passing to the plugin initialization. For example, you should specify:
Opt('user-domain-id')
which will pass the value as user_domain_id to the plugin’s initialization.
Parameters: |
|
---|
Bases: object
Return if the plugin is available for loading.
If a plugin is missing dependencies or for some other reason should not be available to the current system it should override this property and return False to exclude itself from the plugin list.
Return type: | bool |
---|
Create a plugin from the options available for the loader.
Given the options that were specified by the loader create an appropriate plugin. You can override this function in your loader.
This used to be specified by providing the plugin_class property and this is still supported, however specifying a property didn’t let you choose a plugin type based upon the options that were presented.
Override this function if you wish to return different plugins based on the options presented, otherwise you can simply provide the plugin_class property.
Added 2.9
Return the list of parameters associated with the auth plugin.
This list may be used to generate CLI or config arguments.
Returns: | A list of Param objects describing available plugin parameters. |
---|---|
Return type: | list |
Create a plugin from the arguments retrieved from get_options.
A client can override this function to do argument validation or to handle differences between the registered options and what is required to create the plugin.
Load a plugin from getter function that returns appropriate values.
To handle cases other than the provided CONF and CLI loading you can specify a custom loader function that will be queried for the option value. The getter is a function that takes a keystoneauth1.loading.Opt and returns a value to load with.
Parameters: | getter (callable) – A function that returns a value for the given opt. |
---|---|
Returns: | An authentication Plugin. |
Return type: | keystoneauth1.plugin.BaseAuthPlugin |
Get the names of all the plugins that are available on the system.
This is particularly useful for help and error text to prompt a user for example what plugins they may specify.
Returns: | A list of names. |
---|---|
Return type: | frozenset |
Retrieve all the plugin classes available on the system.
Returns: | A dict with plugin entrypoint name as the key and the plugin loader as the value. |
---|---|
Return type: | dict |
Retrieve a plugin class by its entrypoint name.
Parameters: | name (str) – The name of the object to get. |
---|---|
Returns: | An auth plugin class. |
Return type: | keystoneauth1.loading.BaseLoader |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Bases: keystoneauth1.loading.base.BaseLoader
Base Option handling for identity plugins.
This class defines options and handling that should be common across all plugins that are developed against the OpenStack identity service. It provides the options expected by the keystoneauth1.identity.BaseIdentityPlugin class.
Bases: keystoneauth1.loading.identity.BaseIdentityLoader
Base Option handling for identity plugins.
This class defines options and handling that should be common to the V2 identity API. It provides the options expected by the keystoneauth1.identity.v2.Auth class.
Bases: keystoneauth1.loading.identity.BaseIdentityLoader
Base Option handling for identity plugins.
This class defines options and handling that should be common to the V3 identity API. It provides the options expected by the keystoneauth1.identity.v3.Auth class.
Bases: keystoneauth1.loading.identity.BaseV3Loader
Base Option handling for federation plugins.
This class defines options and handling that should be common to the V3 identity federation API. It provides the options expected by the keystoneauth1.identity.v3.FederationBaseAuth class.
Bases: keystoneauth1.loading.identity.BaseIdentityLoader
Base Option handling for generic plugins.
This class defines options and handling that should be common to generic plugins. These plugins target the OpenStack identity service however are designed to be independent of API version. It provides the options expected by the keystoneauth1.identity.v3.BaseGenericPlugin class.
Register CLI options needed to create a plugin.
The function inspects the provided arguments so that it can also register the options required for that specific plugin if available.
Parameters: |
|
---|---|
Returns: | The plugin class that will be loaded or None if not provided. |
Return type: | |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Retrieve the created plugin from the completed argparse results.
Loads and creates the auth plugin from the information parsed from the command line by argparse.
Parameters: | namespace (Namespace) – The result from CLI parsing. |
---|---|
Returns: | An auth plugin, or None if a name is not provided. |
Return type: | keystoneauth1.plugin.BaseAuthPlugin |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Get the oslo_config options common for all auth plugins.
These may be useful without being registered for config file generation or to manipulate the options before registering them yourself.
auth_type: | The name of the plugin to load. |
---|---|
auth_section: | The config file section to load options from. |
Returns: | A list of oslo_config options. |
---|
Get the oslo_config options for a specific plugin.
This will be the list of config options that is registered and loaded by the specified plugin.
Parameters: | plugin (str or keystoneauth1._loading.BaseLoader) – The name of the plugin loader or a plugin loader object |
---|---|
Returns: | A list of oslo_config options. |
Register the oslo_config options that are needed for a plugin.
This only registers the basic options shared by all plugins. Options that are specific to a plugin are loaded just before they are read.
The defined options are:
- auth_type: the name of the auth plugin that will be used for
authentication.
- auth_section: the group from which further auth plugin options should be
taken. If section is not provided then the auth plugin options will be taken from the same group as provided in the parameters.
Parameters: |
|
---|
Load a plugin from an oslo_config CONF object.
Each plugin will register their own required options and so there is no standard list and the plugin should be consulted.
The base options should have been registered with register_conf_options before this function is called.
Parameters: |
|
---|---|
Returns: | An authentication Plugin or None if a name is not provided |
Return type: | |
Raises keystoneauth1.exceptions.auth_plugins.NoMatchingPlugin: | |
if a plugin cannot be created. |
Bases: object
An option required by an authentication plugin.
Opts provide a means for authentication plugins that are going to be dynamically loaded to specify the parameters that are to be passed to the plugin on initialization.
The Opt specifies information about the way the plugin parameter is to be represented in different loading mechanisms.
When defining an Opt with a - the - should be present in the name parameter. This will automatically be converted to an _ when passing to the plugin initialization. For example, you should specify:
Opt('user-domain-id')
which will pass the value as user_domain_id to the plugin’s initialization.
Parameters: |
|
---|