Merge "Added modules which allow to check and manage services statuses."
diff --git a/_modules/runtest/tempest_sections/dashboard.py b/_modules/runtest/tempest_sections/dashboard.py
index b28781e..369bdda 100644
--- a/_modules/runtest/tempest_sections/dashboard.py
+++ b/_modules/runtest/tempest_sections/dashboard.py
@@ -20,12 +20,21 @@
return
nginx_enable = conditions.BaseRule('nginx.server.enabled', 'eq', True)
+ haproxy_enable = conditions.BaseRule('haproxy.proxy.enabled', 'eq', True, multiple='any')
if self.get_item_when_condition_match('horizon.server.enabled', horizon_enable):
if self.get_item_when_condition_match('nginx.server.site.nginx_proxy_openstack_web.enabled', nginx_enable):
port = self.get_item_when_condition_match('nginx.server.site.nginx_proxy_openstack_web.host.port', nginx_enable)
protocol = self.get_item_when_condition_match('nginx.server.site.nginx_proxy_openstack_web.host.protocol', nginx_enable)
ip = self.get_item_when_condition_match('nginx.server.site.nginx_proxy_openstack_web.host.name', nginx_enable)
+ elif self.get_item_when_condition_match('haproxy.proxy.listen.openstack_web', haproxy_enable):
+ binds_data = self.get_item_when_condition_match('haproxy.proxy.listen.openstack_web.binds', haproxy_enable)
+ ip = binds_data[0]['address']
+ port = binds_data[0]['port']
+ if port == 443:
+ protocol = 'https'
+ else:
+ protocol = binds_data[0]['protocol']
else:
port = self.get_item_when_condition_match('horizon.server.bind.port', horizon_enable)
protocol = 'http'