Default pre_deployments/post_deployments to empty lists

This is needed because these aren't defined by default when deploying
without config-download-environment.yaml and
https://review.openstack.org/#/c/508189/, but it's still useful to allow
re-running the deploy steps for debugging, e.g:

ansible-playbook -v -i /usr/bin/tripleo-ansible-inventory deploy_steps_playbook.yaml

Currently this doesn't work anymore, because these variables are undefined.

Change-Id: I2d99c1cb8bf4ccd8581e78d914d438e5de544219
This commit is contained in:
Steven Hardy 2017-10-17 17:33:14 +01:00
parent e3a80b18e0
commit afba3b12bd
1 changed files with 2 additions and 2 deletions

View File

@ -349,7 +349,7 @@ outputs:
vars:
force: false
when: role_name == '{{role.name}}'
with_items: "{{ '{{' }} {{role.name}}_pre_deployments {{ '}}' }}"
with_items: "{{ '{{' }} {{role.name}}_pre_deployments|default([]) {{ '}}' }}"
{%- endfor %}
- hosts: overcloud
name: Deployment steps
@ -372,7 +372,7 @@ outputs:
vars:
force: false
when: role_name == '{{role.name}}'
with_items: "{{ '{{' }} {{role.name}}_post_deployments {{ '}}' }}"
with_items: "{{ '{{' }} {{role.name}}_post_deployments|default([]) {{ '}}' }}"
{%- endfor %}
update_steps_tasks: |
{%- for role in roles %}