Merge "Run "nova-status upgrade check" during install and upgrade"

This commit is contained in:
Zuul 2018-07-11 20:36:23 +00:00 committed by Gerrit Code Review
commit 2a7f7ada39

View File

@ -173,3 +173,26 @@
first_conductor: "{{ groups[nova_services['nova-conductor']['group']][0] }}"
tags:
- nova-config
# The nova-status upgrade check command is typically run after upgrading the
# controller services to new code, but is also OK to run for a greenfield
# install to verify everything is setup correctly. This must run after cell
# mapping setup and online data migrations have run.
# https://docs.openstack.org/nova/latest/cli/nova-status.html
- name: Run nova-status
command: "{{ nova_bin }}/nova-status upgrade check"
become: yes
become_user: "{{ nova_system_user_name }}"
register: nova_status_upgrade_check
# The nova-status upgrade check command has three standard return codes:
# 0: all checks were successful
# 1: warning: there might be some checks that require investigation, but
# generally will not block an automated install/upgrade; digging into
# warnings is useful for debugging post-install/upgrade issues
# 2: at least one check failed and must stop the install/upgrade because
# something was not setup properly
failed_when: "nova_status_upgrade_check.rc not in [0, 1]"
changed_when: false
when:
# Only run nova-status on controller nodes.
- "nova_services['nova-conductor']['group'] in group_names"