catch unsupported osfamily

Previously, param lookups were returning nil. This
leads to a more obvious error message.
This commit is contained in:
Dan Bode 2012-10-29 12:55:31 -07:00
parent 104baec9ea
commit ac334c1f9d

View File

@ -4,20 +4,19 @@ class cinder::params {
$cinder_conf = '/etc/cinder/cinder.conf'
$cinder_paste_api_ini = '/etc/cinder/api-paste.ini'
case $::osfamily {
'Debian': {
$package_name = 'cinder-common'
$api_package = 'cinder-api'
$api_service = 'cinder-api'
$scheduler_package = 'cinder-scheduler'
$scheduler_service = 'cinder-scheduler'
$volume_package = 'cinder-volume'
$volume_service = 'cinder-volume'
$db_sync_command = 'cinder-manage db sync'
if $::osfamily == 'Debian' {
$package_name = 'cinder-common'
$api_package = 'cinder-api'
$api_service = 'cinder-api'
$scheduler_package = 'cinder-scheduler'
$scheduler_service = 'cinder-scheduler'
$volume_package = 'cinder-volume'
$volume_service = 'cinder-volume'
$db_sync_command = 'cinder-manage db sync'
$tgt_package_name = 'tgt'
$tgt_service_name = 'tgt'
}
$tgt_package_name = 'tgt'
$tgt_service_name = 'tgt'
} else {
fail("unsuported osfamily ${::osfamily}, currently Debian is the only supported platform")
}
}