Fix cinder playbook undefined variable

If you run the cinder playbook with the tag rsyslog_client-install, then
cinder_all_software_updated can be unset. This patch fix the error by
checking if the variable is defined before call.

Change-Id: I7c7e66a56ae00275d4f57538c374038bfd1e8e65
Closes-Bug: 1835631
This commit is contained in:
Kourosh Vivan 2019-09-23 11:33:20 +02:00
parent e7f82ba7ef
commit dab5f0071d
1 changed files with 1 additions and 0 deletions

View File

@ -115,6 +115,7 @@
- { name: "cinder-volume", action: "reloaded" }
- { name: "cinder-backup", action: "reloaded" }
when:
- "cinder_all_software_updated is defined"
- "cinder_all_software_updated | bool"
- "ansible_local['openstack_ansible']['cinder']['need_service_restart'] | bool"