Fix cinder_backup for horizon dashboard and heat

We specify the "horizon_enable_cinder_backup" and the
"heat_cinder_backups_enabled" settings to be the value of
"cinder_service_backup_program_enabled" if defined. However that
variable is never exposed to the horizon or heat group_vars, so it will
always be undefined, and the feature will never be enabled for heat or
horizon.

We should set these to the variable on localhost, which is how we specify
it for tempest and cinder, since that variable exists as a host_var it
will always exist.

Change-Id: Ibf2a32e03733185fa4bfe9274c65050e12317e6b
This commit is contained in:
Andy McCrae 2017-11-06 12:07:27 +00:00
parent bbfb9d3339
commit 6f991b91f2
2 changed files with 2 additions and 2 deletions

View File

@ -41,7 +41,7 @@ heat_package_state: "{{ package_state }}"
# Only enable the heat cinder backups functionality if the cinder backup
# service is enabled.
heat_cinder_backups_enabled: "{{ (cinder_service_backup_program_enabled is defined and cinder_service_backup_program_enabled | bool) | ternary(True, False) }}"
heat_cinder_backups_enabled: "{{ hostvars['localhost']['cinder_service_backup_program_enabled'] }}"
# venv fetch configuration
heat_venv_tag: "{{ venv_tag }}"

View File

@ -15,7 +15,7 @@
horizon_external_ssl: "{{ openstack_external_ssl }}"
horizon_service_region: "{{ service_region }}"
horizon_enable_cinder_backup: "{{ cinder_service_backup_program_enabled is defined and cinder_service_backup_program_enabled | bool }}"
horizon_enable_cinder_backup: "{{ hostvars['localhost']['cinder_service_backup_program_enabled'] }}"
horizon_enable_ironic_ui: "{{ (groups['ironic_all'] is defined) and (groups['ironic_all'] | length > 0) }}"
horizon_enable_magnum_ui: "{{ (groups['magnum_all'] is defined) and (groups['magnum_all'] | length > 0) }}"
horizon_enable_designate_ui: "{{ (groups['designate_all'] is defined) and (groups['designate_all'] | length > 0) }}"