From 047dffdd01db04a12ef5eb43a6ac78bd3d30cfce Mon Sep 17 00:00:00 2001 From: Matt Martz Date: Thu, 6 Nov 2014 16:41:34 -0600 Subject: [PATCH] Fix rax_find_loadbalancer issues * Loadbalancer IDs are not UUIDs * Ensure found list exists before using it --- lib/ansible/module_utils/rax.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/module_utils/rax.py b/lib/ansible/module_utils/rax.py index a8f33208caf..75363b1aacb 100644 --- a/lib/ansible/module_utils/rax.py +++ b/lib/ansible/module_utils/rax.py @@ -173,9 +173,9 @@ def rax_find_server(module, rax_module, server): def rax_find_loadbalancer(module, rax_module, loadbalancer): clb = rax_module.cloud_loadbalancers try: - UUID(loadbalancer) found = clb.get(loadbalancer) except: + found = [] for lb in clb.list(): if loadbalancer == lb.name: found.append(lb)