Fix cinder-vmware for env with ceph for volumes

Change-Id: I61e4d728bf597dff5d9a06156d74e8cc1d3bbb9f
Closes-Bug: #1493441
This commit is contained in:
Alexander Arzhanov
2015-09-10 11:19:03 +03:00
parent aac7244cf7
commit 36eb3e60e9

View File

@@ -40,6 +40,20 @@ define vmware::cinder::vmdk(
$cinder_volume_log = "${cinder_log_dir}/vmware-${index}.log"
$cinder_conf = '/etc/cinder/cinder.conf'
$cinder_volume_vmware = "${::cinder::params::volume_service}-vmware"
$storage_hash = hiera('storage', {})
$nodes_hash = hiera('nodes', {})
$roles = node_roles($nodes_hash, hiera('uid'))
if ($storage_hash['volumes_ceph']) and
!(member($roles, 'primary-controller') or
member($roles, 'controller')) {
service { 'cinder-volume':
enable => false,
ensure => stopped,
name => $::cinder::params::volume_service,
hasstatus => true,
}
}
if ! defined(File[$cinder_conf_dir]) {
file { $cinder_conf_dir: