libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Markos Gogoulos (JIRA)" <>
Subject [jira] [Created] (LIBCLOUD-503) OpenStack public ip addresses fix
Date Fri, 31 Jan 2014 11:46:09 GMT
Markos Gogoulos created LIBCLOUD-503:

             Summary: OpenStack public ip addresses fix
                 Key: LIBCLOUD-503
             Project: Libcloud
          Issue Type: Bug
            Reporter: Markos Gogoulos

this is necessary for HP Cloud list_nodes to get public ip addresses (probably other OpenStack
clouds too?)

Problem is that on _to_node function of compute/drivers/
response (api_node['addresses']) is something like
{'private': [{'version': 4, 'addr': ''}, {'version': 4, 'addr': ''}]}

So it goes immediately on the private ip addresses (which is wrong)

        public_networks_labels = ['public', 'internet']

        public_ips, private_ips = [], []
        for label, values in api_node['addresses'].items():
            ips = [v['addr'] for v in values]

            if label in public_networks_labels:

This message was sent by Atlassian JIRA

View raw message