Merge "Clean up previous osa inventory dir before deployment"

This commit is contained in:
Zuul 2018-09-29 19:23:39 +00:00 committed by Gerrit Code Review
commit d957847f5d
2 changed files with 19 additions and 11 deletions

View File

@ -116,8 +116,23 @@ outputs:
external_deploy_tasks:
list_concat:
- get_attr: [OpenShiftNode, role_data, external_deploy_tasks]
- - name: openshift_master step 2
when: step == '2'
- - name: openshift_master step 1
when: step == '1'
tags: openshift
block:
# NOTE(mandre) Remove inventory directory as it may contain
# obsolete files that can mess up the current deployment
- name: remove inventory directory if it exists
file:
path: "{{playbook_dir}}/openshift/inventory"
state: absent
- name: create openshift inventory directory
file:
path: "{{playbook_dir}}/openshift/inventory"
state: directory
- name: openshift_master step 3
when: step == '3'
tags: openshift
block:
- name: set openshift global vars fact

View File

@ -68,17 +68,10 @@ outputs:
upgrade_tasks: []
step_config: ''
external_deploy_tasks:
- name: openshift_node step 1
when: step == '1'
- name: openshift_node step 2
when: step == '2'
tags: openshift
block:
- name: create openshift temp dirs
file:
path: "{{item}}"
state: directory
with_items:
- "{{playbook_dir}}/openshift/inventory"
- name: set role facts for generating inventory
set_fact:
tripleo_role_name: {get_param: RoleName}