aboutsummaryrefslogtreecommitdiffstats
path: root/puppet/puppet-steps.j2
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2017-07-18 02:45:49 +0000
committerGerrit Code Review <review@openstack.org>2017-07-18 02:45:49 +0000
commit96f6010004aef064fdb7b6d7c8eb2884b6795650 (patch)
treeb01e49931233fe2c223fb5b30a92571a36b004da /puppet/puppet-steps.j2
parenteeec8797591fe7268d24c9e6ff1c38750173f746 (diff)
parent68e582323e8d02638b31575f1c6aa40380cb1d0f (diff)
Merge "Handles {controller,NovaCompute}ExtraConfig deprecation in ovecloud.j2"
Diffstat (limited to 'puppet/puppet-steps.j2')
-rw-r--r--puppet/puppet-steps.j253
1 files changed, 26 insertions, 27 deletions
diff --git a/puppet/puppet-steps.j2 b/puppet/puppet-steps.j2
index 55aa6856..3d071018 100644
--- a/puppet/puppet-steps.j2
+++ b/puppet/puppet-steps.j2
@@ -1,16 +1,15 @@
{% set deploy_steps_max = 6 %}
-
conditions:
{% for step in range(1, deploy_steps_max) %}
WorkflowTasks_Step{{step}}_Enabled:
or:
- {% for role in roles %}
+ {%- for role in roles %}
- not:
equals:
- get_param: [role_data, {{role.name}}, service_workflow_tasks, step{{step}}]
- ''
- False
- {% endfor %}
+ {%- endfor %}
{% endfor %}
resources:
@@ -50,16 +49,16 @@ resources:
# WorkflowTasks_StepX resource and can be remove
# if https://bugs.launchpad.net/heat/+bug/1700569
# is fixed.
- {% if step == 1 %}
- {% for dep in roles %}
+ {%- if step == 1 %}
+ {%- for dep in roles %}
- {{dep.name}}PreConfig
- {{dep.name}}ArtifactsDeploy
- {% endfor %}
- {% else %}
- {% for dep in roles %}
+ {%- endfor %}
+ {%- else %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step{{step -1}}
- {% endfor %}
- {% endif %}
+ {%- endfor %}
+ {%- endif %}
properties:
name: {{role.name}}Deployment_Step{{step}}
servers: {get_param: [servers, {{role.name}}]}
@@ -74,9 +73,9 @@ resources:
# after all the previous deployment steps.
{{role.name}}ExtraConfigPost:
depends_on:
- {% for dep in roles %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step5
- {% endfor %}
+ {%- endfor %}
type: OS::TripleO::NodeExtraConfigPost
properties:
servers: {get_param: [servers, {{role.name}}]}
@@ -87,9 +86,9 @@ resources:
{{role.name}}PostConfig:
type: OS::TripleO::Tasks::{{role.name}}PostConfig
depends_on:
- {% for dep in roles %}
+ {%- for dep in roles %}
- {{dep.name}}ExtraConfigPost
- {% endfor %}
+ {%- endfor %}
properties:
servers: {get_param: servers}
input_values:
@@ -104,16 +103,16 @@ resources:
type: OS::Mistral::Workflow
condition: WorkflowTasks_Step{{step}}_Enabled
depends_on:
- {% if step == 1 %}
- {% for dep in roles %}
+ {%- if step == 1 %}
+ {%- for dep in roles %}
- {{dep.name}}PreConfig
- {{dep.name}}ArtifactsDeploy
- {% endfor %}
- {% else %}
- {% for dep in roles %}
+ {%- endfor %}
+ {%- else %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step{{step -1}}
- {% endfor %}
- {% endif %}
+ {%- endfor %}
+ {%- endif %}
properties:
name: {list_join: [".", ["tripleo", {get_param: stack_name}, "workflowtasks", "step{{step}}"]]}
type: direct
@@ -121,9 +120,9 @@ resources:
yaql:
expression: $.data.where($ != '').select($.get('step{{step}}')).where($ != null).flatten()
data:
- {% for role in roles %}
+ {%- for role in roles %}
- get_param: [role_data, {{role.name}}, service_workflow_tasks]
- {% endfor %}
+ {%- endfor %}
WorkflowTasks_Step{{step}}_Execution:
type: OS::Mistral::ExternalResource
@@ -137,18 +136,18 @@ resources:
env:
service_ips: { get_param: ctlplane_service_ips }
role_merged_configs:
- {% for r in roles %}
+ {%- for r in roles %}
{{r.name}}: {get_param: [role_data, {{r.name}}, merged_config_settings]}
- {% endfor %}
+ {%- endfor %}
UPDATE:
workflow: { get_resource: WorkflowTasks_Step{{step}} }
params:
env:
service_ips: { get_param: ctlplane_service_ips }
role_merged_configs:
- {% for r in roles %}
+ {%- for r in roles %}
{{r.name}}: {get_param: [role_data, {{r.name}}, merged_config_settings]}
- {% endfor %}
+ {%- endfor %}
always_update: true
{% endfor %}
# END service_workflow_tasks handling