Browse Source

Merge pull request #266 from detiber/issue_257

Guard against openstack bug 1334857
Thomas Wiest 9 years ago
parent
commit
e903a6b5be
1 changed files with 2 additions and 2 deletions
  1. 2 2
      roles/openshift_facts/library/openshift_facts.py

+ 2 - 2
roles/openshift_facts/library/openshift_facts.py

@@ -242,8 +242,8 @@ def normalize_openstack_facts(metadata, facts):
     # metadata api, should be updated if neutron exposes this.
 
     facts['zone'] = metadata['availability_zone']
-
-    facts['network']['ip'] = metadata['ec2_compat']['local-ipv4']
+    local_ipv4 = metadata['ec2_compat']['local-ipv4'].split(',')[0]
+    facts['network']['ip'] = local_ipv4
     facts['network']['public_ip'] = metadata['ec2_compat']['public-ipv4']
 
     # TODO: verify local hostname makes sense and is resolvable