diff --git a/vmware_nsx/services/lbaas/nsx_v/v2/listener_mgr.py b/vmware_nsx/services/lbaas/nsx_v/v2/listener_mgr.py index 7920fae28f..50879c32b1 100644 --- a/vmware_nsx/services/lbaas/nsx_v/v2/listener_mgr.py +++ b/vmware_nsx/services/lbaas/nsx_v/v2/listener_mgr.py @@ -35,7 +35,7 @@ def listener_to_edge_app_profile(listener, edge_cert_id): 'name': listener.id, 'serverSslEnabled': False, 'sslPassthrough': False, - 'template': listener.protocol, + 'template': lb_const.PROTOCOL_MAP[listener.protocol], } if (listener.protocol == lb_const.LB_PROTOCOL_HTTPS diff --git a/vmware_nsx/tests/unit/nsx_v/test_edge_loadbalancer_driver_v2.py b/vmware_nsx/tests/unit/nsx_v/test_edge_loadbalancer_driver_v2.py index 2920092ce2..4dca29cc48 100644 --- a/vmware_nsx/tests/unit/nsx_v/test_edge_loadbalancer_driver_v2.py +++ b/vmware_nsx/tests/unit/nsx_v/test_edge_loadbalancer_driver_v2.py @@ -38,7 +38,7 @@ LISTENER_ID = 'xxx-111' EDGE_APP_PROFILE_ID = 'appp-x' EDGE_APP_PROF_DEF = {'sslPassthrough': False, 'insertXForwardedFor': False, 'serverSslEnabled': False, 'name': LISTENER_ID, - 'template': 'HTTP'} + 'template': 'http'} EDGE_VIP_ID = 'vip-aaa' EDGE_VIP_DEF = {'protocol': 'http', 'name': 'vip_' + LISTENER_ID, 'connectionLimit': 0, 'defaultPoolId': None,