This is about choosing a value for the ipaddress attribute, not making it easier to retrieve an address from a specific addresses like in OHAI-88, right?
Bryan McLellan [Opscode]
added a comment - This is about choosing a value for the ipaddress attribute, not making it easier to retrieve an address from a specific addresses like in OHAI-88 , right?
Laurent Désarmes
added a comment - correct.
at the moment, i'm working on OHAI-355 , i should be resolving it in the next hours if by any chance you want to review it.
the plugin tries to be a bit smarter, it does sort ip addresses by scope, by prefixlen and then by ip
address to help setting the ipaddress and ip6address attributes.
one major change, it will set macaddress from the ipv6 setup if the node has no ipv4. otherwise ipv4 has precedence.
For ex: if the ipv4 default_interface has NOARP, it won't set macaddress to the default_inet6_interface
Laurent Désarmes
added a comment - the plugin tries to be a bit smarter, it does sort ip addresses by scope, by prefixlen and then by ip
address to help setting the ipaddress and ip6address attributes.
one major change, it will set macaddress from the ipv6 setup if the node has no ipv4. otherwise ipv4 has precedence.
For ex: if the ipv4 default_interface has NOARP, it won't set macaddress to the default_inet6_interface
Bryan McLellan [Opscode]
added a comment - Note to myself, with Ohai 6.14.0.rc.1, I cannot get default_interface on CentOS 6.0 and OS X 10.6.8. Check if this patch fixes this.
proof of concept in https://github.com/llaurent/ohai/compare/OHAI-355