f1d3ff11d0
If any nova compute service fails to register itself, Kolla Ansible will fail the host that queries the Nova API. This is the first compute host in the inventory, and fails in the task: Waiting for nova-compute services to register themselves Other hosts continue, often leading to further errors later on. Clearly this is not idea. This change modifies the behaviour to query the compute service list until all expected hosts are present, but does not fail the querying host if they are not. A new task is added that executes for all hosts, and fails only those hosts that have not registered successfully. Alternatively, to fail all hosts in a cell when any compute service fails to register, set nova_compute_registration_fatal to true. Change-Id: I12c1928cf1f1fb9e28f1741e7fe4968004ea1816 Closes-Bug: #1940119
38 lines
1.2 KiB
YAML
38 lines
1.2 KiB
YAML
---
|
|
- include_tasks: clone.yml
|
|
when: nova_dev_mode | bool
|
|
|
|
- import_tasks: config-host.yml
|
|
|
|
- import_tasks: config.yml
|
|
|
|
- import_tasks: check-containers.yml
|
|
|
|
- include_tasks: config-nova-fake.yml
|
|
when:
|
|
- enable_nova_fake | bool
|
|
- inventory_hostname in groups[nova_cell_compute_group]
|
|
|
|
- name: Flush handlers
|
|
meta: flush_handlers
|
|
|
|
- import_tasks: wait_discover_computes.yml
|
|
vars:
|
|
# List of virtualised compute hypervisors in this Ansible play batch.
|
|
virt_computes_in_batch: >-
|
|
{{ groups[nova_cell_compute_group] |
|
|
intersect(ansible_play_batch) |
|
|
list }}
|
|
# List of iroinc compute hosts in this Ansible play batch.
|
|
ironic_computes_in_batch: >-
|
|
{{ (groups[nova_cell_compute_ironic_group] |
|
|
intersect(ansible_play_batch) |
|
|
list)
|
|
if nova_cell_services['nova-compute-ironic'].enabled | bool else [] }}
|
|
all_computes_in_batch: "{{ virt_computes_in_batch + ironic_computes_in_batch }}"
|
|
when:
|
|
# Run discovery when one or more compute hosts are in the Ansible batch,
|
|
# and there is a cell conductor in the inventory to delegate to.
|
|
- all_computes_in_batch | length > 0
|
|
- groups[nova_cell_conductor_group] | length > 0
|