Parallelize server pre and post steps

Update the play for the server pre and post steps so that the tasks run
in parallel across all roles, instead of doing one role at a time. By
not using the "when" attribute, and relying on the tripleo_role_name var
for the list of deployments, we can force these tasks to run in parallel
across all roles.

Change-Id: I83a4deaa68d5788edb5ab13652bb30c762f337d8
This commit is contained in:
James Slagle 2018-06-11 17:55:13 -04:00
parent beeda14b65
commit 6b506eea2c

View File

@ -446,13 +446,10 @@ outputs:
gather_facts: no
any_errors_fatal: yes
tasks:
{%- for role in roles %}
- include_tasks: {{role.name}}/deployments.yaml
- include_tasks: deployments.yaml
vars:
force: false
when: tripleo_role_name == '{{role.name}}'
with_items: "{{ '{{' }} {{role.name}}_pre_deployments|default([]) {{ '}}' }}"
{%- endfor %}
with_items: "{{ '{{' }} lookup('vars', tripleo_role_name + '_pre_deployments')|default([]) {{ '}}' }}"
tags:
- overcloud
- pre_deploy_steps
@ -525,13 +522,10 @@ outputs:
gather_facts: no
any_errors_fatal: yes
tasks:
{%- for role in roles %}
- include_tasks: {{role.name}}/deployments.yaml
- include_tasks: deployments.yaml
vars:
force: false
when: tripleo_role_name == '{{role.name}}'
with_items: "{{ '{{' }} {{role.name}}_post_deployments|default([]) {{ '}}' }}"
{%- endfor %}
with_items: "{{ '{{' }} lookup('vars', tripleo_role_name + '_post_deployments')|default([]) {{ '}}' }}"
tags:
- overcloud
- post_deploy_steps