On 15 February 2011 21:43, Richard Crowley <r...@rcrowley.org> wrote:
> While Matt and I were pairing on getting IPv6 support into facter we
> ran across some code that, on Darwin, would try and DWIM out the
> "main" address of the system. Specifically, it assumed that the
> "main" IP address of a machine was the one associated with a default
> route.
>
> I have recreated this behavior in a custom fact on Linux before and would
> support it being  declared the correct behavior everywhere.

IMO this is site specific and we can't do the right thing, it's one of
the areas where there may be the common case but it's not by any means
conclusive.


> Being able to say programatically that ipaddress_eth1 is the answer when
> someone asks for ipaddress would be cool and then the default route looks
> like a reasonable default - nothing more.

Based on previous discussions with facter users I don't think we can
make this assumption. Now enabling easy labelling/aliasing of facts to
help make the code in puppet more readable is probably a reasonable
compromise. As is having rich data so you could say:

${route.default.interfaces}, but even then with bonding, etc it may be
more complex than a 1:1 mapping.

Paul

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Developers" group.
To post to this group, send email to puppet-dev@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-dev?hl=en.

Reply via email to