Do not create nova db user if database unchanged

This change prevents the task running if the database
has not been changed when a preconfigured external
database is not in use. This was the behaviour before
the preconfigured database feature was introduced.

Close-Bug: 1763375
Change-Id: I4f68905732dac75bc0deddab88047c9c0d7d65b5
This commit is contained in:
Doug Szumski 2018-04-12 14:30:42 +01:00
parent ed9854248f
commit 67d4fdd2af

View File

@ -44,7 +44,9 @@
database_password: "{{ nova_api_database_password }}"
run_once: True
delegate_to: "{{ groups['nova-api'][0] }}"
when: database.changed or not use_preconfigured_databases | bool
when:
- database.changed
- not use_preconfigured_databases | bool
- include: bootstrap_service.yml
when: database.changed or use_preconfigured_databases | bool