Make providers use auth_url for authentication
When reading credentials from the configuration's keystone_authtoken section www_authenticate_uri was used as URL for Keystone. As www_authenticate_uri is a public endpoint that is not necessarily reachable for the Puppet agent, this change uses the more appropriate auth_url as Keystone URL. Change-Id: I9b2e85842fb9a6ec75158bc612b47a4b64f169f9
This commit is contained in:
parent
23d4b816a7
commit
9c96f348b4
@ -26,7 +26,7 @@ class Puppet::Provider::Gnocchi < Puppet::Provider
|
||||
end
|
||||
|
||||
def self.get_gnocchi_credentials
|
||||
auth_keys = ['www_authenticate_uri', 'project_name', 'username', 'password']
|
||||
auth_keys = ['auth_url', 'project_name', 'username', 'password']
|
||||
conf = gnocchi_conf
|
||||
if conf and conf['keystone_authtoken'] and
|
||||
auth_keys.all?{|k| !conf['keystone_authtoken'][k].nil?}
|
||||
@ -64,7 +64,7 @@ correctly configured.")
|
||||
def self.auth_gnocchi(*args)
|
||||
q = gnocchi_credentials
|
||||
authenv = {
|
||||
:OS_AUTH_URL => q['www_authenticate_uri'],
|
||||
:OS_AUTH_URL => q['auth_url'],
|
||||
:OS_USERNAME => q['username'],
|
||||
:OS_TENANT_NAME => q['project_name'],
|
||||
:OS_PASSWORD => q['password'],
|
||||
|
Loading…
Reference in New Issue
Block a user