969693e667
When we clear the cached facts with unreachable nodes, we attempt to gather facts by default. This can cause the node to be skipped for every future playbook. This ends up bypassing all our failure percentage logic. Change-Id: Ie240877496b73a37f553a84af47dfebdbaf899e5 Related-Bug: 1908573
65 lines
1.7 KiB
YAML
65 lines
1.7 KiB
YAML
---
|
|
# If a new play with potential facts gathering is added, make sure we set:
|
|
# any_errors_fatal: false
|
|
# ignore_unreachable: true
|
|
# So we don't break the MaxFailPercentage feature since these plays can't use
|
|
# Ansible strategies.
|
|
|
|
- hosts: all
|
|
name: Clear cached facts
|
|
# We don't want to gather facts, just clear them
|
|
gather_facts: false
|
|
tasks:
|
|
- meta: clear_facts
|
|
tags:
|
|
- facts
|
|
|
|
- hosts: "{{ deploy_source_host }}:{{ deploy_target_host }}"
|
|
name: Gather facts
|
|
strategy: tripleo_free
|
|
gather_facts: true
|
|
tags:
|
|
- facts
|
|
|
|
- hosts: all
|
|
name: Load global variables
|
|
gather_facts: "{{ gather_facts | default(false) }}"
|
|
any_errors_fatal: false
|
|
ignore_unreachable: true
|
|
tasks:
|
|
- include_vars: global_vars.yaml
|
|
no_log: true
|
|
tags:
|
|
- always
|
|
|
|
- hosts: "{{ deploy_target_host }}"
|
|
name: Render all_nodes data as group_vars for overcloud
|
|
gather_facts: "{{ gather_facts | default(false) }}"
|
|
# we don't skip errors or ignore unreachable on this one because it's
|
|
# delegated to localhost. localhost should never be unreachable (tm)
|
|
any_errors_fatal: True
|
|
tasks:
|
|
- name: Render all_nodes data as group_vars for overcloud
|
|
delegate_to: localhost
|
|
become: false
|
|
run_once: true
|
|
when: not ansible_check_mode|bool
|
|
tripleo_all_nodes_data:
|
|
tags:
|
|
- facts
|
|
- always
|
|
|
|
- hosts: "{{ deploy_target_host }}"
|
|
name: Set all_nodes data as group_vars for overcloud
|
|
gather_facts: "{{ gather_facts | default(false) }}"
|
|
any_errors_fatal: false
|
|
ignore_unreachable: true
|
|
tasks:
|
|
- name: Set all_nodes data as group_vars for overcloud
|
|
include_vars: "{{ playbook_dir }}/group_vars/overcloud.json"
|
|
no_log: true
|
|
when: not ansible_check_mode|bool
|
|
tags:
|
|
- facts
|
|
- always
|