This auth module is intended to allow OpenStack client-tools to select from a variety of authentication strategies, including NoAuth (the default), and Keystone (an identity management system).
> auth_plugin = AuthPlugin(creds)
> auth_plugin.authenticate()
> auth_plugin.auth_token abcdefg
> auth_plugin.management_url http://service_endpoint/
glance.common.auth.
KeystoneStrategy
(creds, insecure=False, configure_via_auth=True)[source]¶Bases: glance.common.auth.BaseStrategy
MAX_REDIRECTS
= 10¶authenticate
()[source]¶Authenticate with the Keystone service.
There are a few scenarios to consider here:
is_authenticated
¶strategy
¶glance.common.auth.
NoAuthStrategy
[source]¶Bases: glance.common.auth.BaseStrategy
is_authenticated
¶strategy
¶glance.common.auth.
get_endpoint
(service_catalog, service_type='image', endpoint_region=None, endpoint_type='publicURL')[source]¶Select an endpoint from the service catalog
We search the full service catalog for services matching both type and region. If the client supplied no region then any ‘image’ endpoint is considered a match. There must be one – and only one – successful match in the catalog, otherwise we will raise an exception.
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.