summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2015-05-22 08:16:24 +0000
committerGerrit Code Review <review@openstack.org>2015-05-22 08:16:24 +0000
commit895bb718f63c8d99a3e51527a71b750841953c5a (patch)
tree25809dc824c9469c2c25e6a70bde66299b5d5c43
parent23c329bbb9fc39f84a9397c59272bd81ab4628fe (diff)
parent69d9d5cf1c3505cb7259a729badd0b6ffc8edeb7 (diff)
Merge "Add Cinder services as Pacemaker resources"
-rw-r--r--puppet/manifests/overcloud_controller_pacemaker.pp58
1 files changed, 51 insertions, 7 deletions
diff --git a/puppet/manifests/overcloud_controller_pacemaker.pp b/puppet/manifests/overcloud_controller_pacemaker.pp
index ce8e81ee..6daa7f87 100644
--- a/puppet/manifests/overcloud_controller_pacemaker.pp
+++ b/puppet/manifests/overcloud_controller_pacemaker.pp
@@ -502,16 +502,16 @@ if hiera('step') >= 3 {
include ::cinder
class { '::cinder::api':
sync_db => $sync_db,
- manage_service => $non_pcmk_start,
- enabled => $non_pcmk_start,
+ manage_service => false,
+ enabled => false,
}
class { '::cinder::scheduler' :
- manage_service => $non_pcmk_start,
- enabled => $non_pcmk_start,
+ manage_service => false,
+ enabled => false,
}
class { '::cinder::volume' :
- manage_service => $non_pcmk_start,
- enabled => $non_pcmk_start,
+ manage_service => false,
+ enabled => false,
}
include ::cinder::glance
class {'cinder::setup_test_volume':
@@ -694,5 +694,49 @@ if hiera('step') >= 3 {
} #END STEP 3
if hiera('step') >= 4 {
- # TODO: pacemaker::resource::service for OpenStack services go here
+ if $pacemaker_master {
+
+ # Cinder
+ pacemaker::resource::service { $::cinder::params::api_service :
+ clone_params => "interleave=true",
+ }
+ pacemaker::resource::service { $::cinder::params::scheduler_service :
+ clone_params => "interleave=true",
+ }
+ pacemaker::resource::service { $::cinder::params::volume_service : }
+
+ pacemaker::constraint::base { 'cinder-api-then-cinder-scheduler-constraint':
+ constraint_type => "order",
+ first_resource => "${::cinder::params::api_service}-clone",
+ second_resource => "${::cinder::params::scheduler_service}-clone",
+ first_action => "start",
+ second_action => "start",
+ require => [Pacemaker::Resource::Service[$::cinder::params::api_service],
+ Pacemaker::Resource::Service[$::cinder::params::scheduler_service]],
+ }
+ pacemaker::constraint::colocation { 'cinder-scheduler-with-cinder-api-colocation':
+ source => "${::cinder::params::scheduler_service}-clone",
+ target => "${::cinder::params::api_service}-clone",
+ score => "INFINITY",
+ require => [Pacemaker::Resource::Service[$::cinder::params::api_service],
+ Pacemaker::Resource::Service[$::cinder::params::scheduler_service]],
+ }
+ pacemaker::constraint::base { 'cinder-scheduler-then-cinder-volume-constraint':
+ constraint_type => "order",
+ first_resource => "${::cinder::params::scheduler_service}-clone",
+ second_resource => "${::cinder::params::volume_service}",
+ first_action => "start",
+ second_action => "start",
+ require => [Pacemaker::Resource::Service[$::cinder::params::scheduler_service],
+ Pacemaker::Resource::Service[$::cinder::params::volume_service]],
+ }
+ pacemaker::constraint::colocation { 'cinder-volume-with-cinder-scheduler-colocation':
+ source => "${::cinder::params::volume_service}",
+ target => "${::cinder::params::scheduler_service}-clone",
+ score => "INFINITY",
+ require => [Pacemaker::Resource::Service[$::cinder::params::scheduler_service],
+ Pacemaker::Resource::Service[$::cinder::params::volume_service]],
+ }
+
+ }
} #END STEP 4