Remove hack the pulls latest docker
[apex-tripleo-heat-templates.git] / extraconfig / tasks / pre_puppet_pacemaker.yaml
1 heat_template_version: 2014-10-16
2 description: 'Pre-Puppet Config for Pacemaker deployments'
3
4 parameters:
5   servers:
6     type: json
7   input_values:
8      type: json
9      description: input values for the software deployments
10
11 resources:
12
13   ControllerPrePuppetMaintenanceModeConfig:
14     type: OS::Heat::SoftwareConfig
15     properties:
16       group: script
17       config: |
18         #!/bin/bash
19         pacemaker_status=$(systemctl is-active pacemaker)
20
21         if [ "$pacemaker_status" = "active" ]; then
22             pcs property set maintenance-mode=true
23         fi
24
25   ControllerPrePuppetMaintenanceModeDeployment:
26     type: OS::Heat::SoftwareDeployments
27     properties:
28       servers:  {get_param: servers}
29       config: {get_resource: ControllerPrePuppetMaintenanceModeConfig}
30       input_values: {get_param: input_values}