ruby-openstack/ruby-openstack — pull request #5 by marios (2012-07-03 11:46:39+00:00)
Title: Fixes labelling of IP Addresses - public vs private 

Current version of OS API isn't clear about distinguishing 'public' and 'private' addresses - see [this post](https://answers.launchpad.net/nova/+question/185110). The terms 'public' and 'private' are used to refer to network names, rather than the address type.

This results in no clear way to distinguish a server's IP addresses (routable/public vs non_routable/private) through the API, as [explained here](http://www.mail-archive.com/openstack@lists.launchpad.net/msg12987.html).

Other bindings, such as hp-fog - [grab the first address](https://github.com/fog/fog/blob/master/lib/fog/hp/requests/compute/list_server_private_addresses.rb#L24) as 'private' and the rest are 'public'. As I can't find this ordering documented anywhere I feel a safer approach is to use pattern matching against 10.0.0.0/8 192.168.0.0/16, 172.16.0.0/12 to determine 'private' addresses - as in the attached commits,

marios