From e2301958e9dd4086fb6f5689499e5bb39e87e208 Mon Sep 17 00:00:00 2001 From: Colleen Murphy Date: Sat, 18 Apr 2015 00:42:07 +0000 Subject: [PATCH] Revert "Fix os_region_name in provider" When we revert the change that moved os_region_name, we must also revert this fix that resulted from that change. Depends on https://review.openstack.org/#/c/174968/ This reverts commit 354ae692a502a6089f4f82b3b58ee2aaa42443a2. Change-Id: I65249b0734ae1a1bfbf0e5e153d19787f6aded5f --- lib/puppet/provider/glance.rb | 8 ++++---- spec/unit/provider/glance_spec.rb | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/puppet/provider/glance.rb b/lib/puppet/provider/glance.rb index 2501d63c..6f7bbee0 100644 --- a/lib/puppet/provider/glance.rb +++ b/lib/puppet/provider/glance.rb @@ -16,7 +16,7 @@ class Puppet::Provider::Glance < Puppet::Provider glance_file['keystone_authtoken']['admin_tenant_name'] and glance_file['keystone_authtoken']['admin_user'] and glance_file['keystone_authtoken']['admin_password'] and - glance_file['glance_store']['os_region_name'] + glance_file['DEFAULT']['os_region_name'] g = {} g['auth_host'] = glance_file['keystone_authtoken']['auth_host'].strip @@ -25,7 +25,7 @@ class Puppet::Provider::Glance < Puppet::Provider g['admin_tenant_name'] = glance_file['keystone_authtoken']['admin_tenant_name'].strip g['admin_user'] = glance_file['keystone_authtoken']['admin_user'].strip g['admin_password'] = glance_file['keystone_authtoken']['admin_password'].strip - g['os_region_name'] = glance_file['glance_store']['os_region_name'].strip + g['os_region_name'] = glance_file['DEFAULT']['os_region_name'].strip # auth_admin_prefix not required to be set. g['auth_admin_prefix'] = (glance_file['keystone_authtoken']['auth_admin_prefix'] || '').strip @@ -36,14 +36,14 @@ class Puppet::Provider::Glance < Puppet::Provider glance_file['keystone_authtoken']['admin_tenant_name'] and glance_file['keystone_authtoken']['admin_user'] and glance_file['keystone_authtoken']['admin_password'] and - glance_file['glance_store']['os_region_name'] + glance_file['DEFAULT']['os_region_name'] g = {} g['identity_uri'] = glance_file['keystone_authtoken']['identity_uri'].strip g['admin_tenant_name'] = glance_file['keystone_authtoken']['admin_tenant_name'].strip g['admin_user'] = glance_file['keystone_authtoken']['admin_user'].strip g['admin_password'] = glance_file['keystone_authtoken']['admin_password'].strip - g['os_region_name'] = glance_file['glance_store']['os_region_name'].strip + g['os_region_name'] = glance_file['DEFAULT']['os_region_name'].strip return g else diff --git a/spec/unit/provider/glance_spec.rb b/spec/unit/provider/glance_spec.rb index 344ec4a2..14d418b9 100644 --- a/spec/unit/provider/glance_spec.rb +++ b/spec/unit/provider/glance_spec.rb @@ -36,7 +36,7 @@ describe Puppet::Provider::Glance do 'admin_user' => 'user', 'admin_password' => 'pass' }, - 'glance_store' => + 'DEFAULT' => { 'os_region_name' => 'SomeRegion', }