diff --git a/manifests/dispersion.pp b/manifests/dispersion.pp index a58fcb45..849064c4 100644 --- a/manifests/dispersion.pp +++ b/manifests/dispersion.pp @@ -84,6 +84,7 @@ class swift::dispersion ( timeout => 0, onlyif => "swift -A ${auth_url} -U ${auth_tenant}:${auth_user} -K ${auth_pass} -V ${auth_version} stat | grep 'Account: '", unless => "swift -A ${auth_url} -U ${auth_tenant}:${auth_user} -K ${auth_pass} -V ${auth_version} list | grep dispersion_", + require => Package["swiftclient"], } } diff --git a/spec/classes/swift_dispersion_spec.rb b/spec/classes/swift_dispersion_spec.rb index 778ac887..b4065591 100644 --- a/spec/classes/swift_dispersion_spec.rb +++ b/spec/classes/swift_dispersion_spec.rb @@ -49,7 +49,8 @@ describe 'swift::dispersion' do :path => ['/bin', '/usr/bin'], :subscribe => 'File[/etc/swift/dispersion.conf]', :onlyif => "swift -A http://127.0.0.1:5000/v2.0/ -U services:dispersion -K dispersion_password -V 2.0 stat | grep 'Account: '", - :unless => "swift -A http://127.0.0.1:5000/v2.0/ -U services:dispersion -K dispersion_password -V 2.0 list | grep dispersion_" + :unless => "swift -A http://127.0.0.1:5000/v2.0/ -U services:dispersion -K dispersion_password -V 2.0 list | grep dispersion_", + :require => 'Package[swiftclient]' )} end