Ensure that swiftclient is installed

It's possible for glance-api to get stuck in a loop starting when
the backend is swift, and python-swiftclient is not present on
the system.

Depends-On: I65fb0736e9fa9e68c3c7877cf6caf228c49eb82d
Change-Id: I1eeb9f12cf82961ae820067ad8fe91d096d1d6e1
Closes-bug: #1632143
This commit is contained in:
Andrew Woodward 2016-10-10 16:15:15 -07:00
parent 74e52d294c
commit 33f96d71ed
3 changed files with 9 additions and 0 deletions

View File

@ -70,6 +70,9 @@ class glance::backend::swift(
) {
include ::glance::deps
include ::swift::client
Class['swift::client'] -> Anchor['glance::install::end']
Service<| tag == 'swift-service' |> -> Service['glance-api']
glance_api_config {
'glance_store/swift_store_region': value => $swift_store_region;

View File

@ -59,6 +59,10 @@
"name": "puppetlabs/stdlib",
"version_requirement": ">=4.2.0 <5.0.0"
},
{
"name": "openstack/swift",
"version_requirement": ">=9.4.0 <10.0.0"
},
{
"name": "openstack/openstacklib",
"version_requirement": ">=9.4.0 <10.0.0"

View File

@ -15,6 +15,8 @@ describe 'glance::backend::swift' do
describe 'when default parameters' do
it { is_expected.to contain_class 'swift::client' }
it 'configures glance-api.conf' do
is_expected.to contain_glance_api_config('glance_store/default_store').with_value('swift')
is_expected.to contain_glance_api_config('glance_store/swift_store_large_object_size').with_value('<SERVICE DEFAULT>')