deployment: drop step6
authorEmilien Macchi <emilien@redhat.com>
Mon, 9 May 2016 19:39:47 +0000 (15:39 -0400)
committerEmilien Macchi <emilien@redhat.com>
Tue, 10 May 2016 22:12:51 +0000 (22:12 +0000)
Step6 was just about confuring fencing after creating all Pacemaker
resources.
It was created by this patch:
https://review.openstack.org/#q,1787fbc7ca58f9965cd5d64b685c1f9beed4cb9b,n,z
A bit of Puppet orchestration can help us to not require an extra step.

This patch:
* configure & enable fencing at step5
* make sure we don't configure fencing because creating Pacemaker
  resources and constraints.
* remove step6 from deployment workflow.
* depends on a patch in puppet-tripleo that moves keystone resources
  (endpoints, roles) to step 5.

Change-Id: Iae33149e4a03cd64c5831e689be8189ad0cf034b
Depends-On: Icea7537cea330da59fe108c9b874c04f2b94d062
Depends-On: I079e65f535af069312b602e8ff58be80ab2f2226

puppet/controller-post.yaml
puppet/manifests/overcloud_controller_pacemaker.pp

index d89abdc..705e4b9 100644 (file)
@@ -102,20 +102,9 @@ resources:
         step: 5
         update_identifier: {get_param: NodeConfigIdentifiers}
 
-  ControllerOvercloudServicesDeployment_Step6:
-    type: OS::Heat::StructuredDeployments
-    depends_on: ControllerOvercloudServicesDeployment_Step5
-    properties:
-      name: ControllerOvercloudServicesDeployment_Step6
-      servers:  {get_param: servers}
-      config: {get_resource: ControllerPuppetConfig}
-      input_values:
-        step: 6
-        update_identifier: {get_param: NodeConfigIdentifiers}
-
   ControllerPostPuppet:
     type: OS::TripleO::Tasks::ControllerPostPuppet
-    depends_on: ControllerOvercloudServicesDeployment_Step6
+    depends_on: ControllerOvercloudServicesDeployment_Step5
     properties:
       servers:  {get_param: servers}
       input_values:
index 0652a1c..0b5aefd 100644 (file)
@@ -46,7 +46,7 @@ if $::hostname == downcase(hiera('bootstrap_nodeid')) {
   $sync_db = false
 }
 
-$enable_fencing = str2bool(hiera('enable_fencing', false)) and hiera('step') >= 6
+$enable_fencing = str2bool(hiera('enable_fencing', false)) and hiera('step') >= 5
 $enable_load_balancer = hiera('enable_load_balancer', true)
 
 # When to start and enable services which haven't been Pacemakerized
@@ -99,6 +99,10 @@ if hiera('step') >= 1 {
   if $enable_fencing {
     include ::tripleo::fencing
 
+    # enable stonith after all Pacemaker resources have been created
+    Pcmk_resource<||> -> Class['tripleo::fencing']
+    Pcmk_constraint<||> -> Class['tripleo::fencing']
+    Exec <| tag == 'pacemaker_constraint' |> -> Class['tripleo::fencing']
     # enable stonith after all fencing devices have been created
     Class['tripleo::fencing'] -> Class['pacemaker::stonith']
   }