The package python-ceph no longer exists in el7, use python-rbd.

Change-Id: I885a11fd33577618138ddffaf0de196e7bb62a77
This commit is contained in:
Crag Wolfe 2015-06-03 18:53:09 -04:00
parent 199d90ec6c
commit ef19c5584d
2 changed files with 33 additions and 1 deletions

View File

@ -3,7 +3,6 @@
class glance::params { class glance::params {
$client_package_name = 'python-glanceclient' $client_package_name = 'python-glanceclient'
$pyceph_package_name = 'python-ceph'
$cache_cleaner_command = 'glance-cache-cleaner' $cache_cleaner_command = 'glance-cache-cleaner'
$cache_pruner_command = 'glance-cache-pruner' $cache_pruner_command = 'glance-cache-pruner'
@ -15,6 +14,11 @@ class glance::params {
$api_service_name = 'openstack-glance-api' $api_service_name = 'openstack-glance-api'
$registry_service_name = 'openstack-glance-registry' $registry_service_name = 'openstack-glance-registry'
$db_sync_command = 'glance-manage --config-file=/etc/glance/glance-registry.conf db_sync' $db_sync_command = 'glance-manage --config-file=/etc/glance/glance-registry.conf db_sync'
if ($::operatingsystem != 'fedora' and versioncmp($::operatingsystemrelease, '7') < 0) {
$pyceph_package_name = 'python-ceph'
} else {
$pyceph_package_name = 'python-rbd'
}
} }
'Debian': { 'Debian': {
$api_package_name = 'glance-api' $api_package_name = 'glance-api'
@ -22,6 +26,7 @@ class glance::params {
$api_service_name = 'glance-api' $api_service_name = 'glance-api'
$registry_service_name = 'glance-registry' $registry_service_name = 'glance-registry'
$db_sync_command = 'glance-manage --config-file=/etc/glance/glance-registry.conf db_sync' $db_sync_command = 'glance-manage --config-file=/etc/glance/glance-registry.conf db_sync'
$pyceph_package_name = 'python-ceph'
} }
default: { default: {
fail("Unsupported osfamily: ${::osfamily} operatingsystem: ${::operatingsystem}, module ${module_name} only support osfamily RedHat and Debian") fail("Unsupported osfamily: ${::osfamily} operatingsystem: ${::operatingsystem}, module ${module_name} only support osfamily RedHat and Debian")

View File

@ -42,4 +42,31 @@ describe 'glance::backend::rbd' do
) )
} }
end end
describe 'package on RedHat platform el6' do
let :facts do
{
:osfamily => 'RedHat',
:operatingsystemrelease => '6.5',
}
end
it { is_expected.to contain_package('python-ceph').with(
:name => 'python-ceph',
:ensure => 'present'
)
}
end
describe 'package on RedHat platform el7' do
let :facts do
{
:osfamily => 'RedHat',
:operatingsystemrelease => '7.0'
}
end
it { is_expected.to contain_package('python-ceph').with(
:name => 'python-rbd',
:ensure => 'present'
)
}
end
end end