Cody Herriges <[email protected]> writes:
> My preliminary work on a new fact that reports IPv6 addresses.
It looks like this reports *an* IPv6 address, not multiple IPv6 addresses,
even though every adapter / host has at least one, and ofter multiple, these
days. You should report all the addresses, link-local included, I would
suggest. That obviously applies to all the implementations. :)
> Since IPv6 interfaces have a link local address even after obtaining a
> routable address the original ipaddress fact code that I had simply modified
> slightly isn't going to work the way I want it to. Everything but the Darwin
> section at the bottom is the old code I originally submitted. I only have
> OSX, Linux, and Solaris to test code on.
I assume that this is code you are actually proposing and have reviewed it as
such. It isn't entirely clear that is what you meant, though, so sorry if I
misunderstood your intention.
[...]
> +Facter.add(:ipaddress6) do
> + confine :kernel => :linux
> + setcode do
> + ip = nil
> + output = %x{/sbin/ifconfig}
This would enormously better use /sbin/ip from iproute2, if available, since
that can report addresses that are simply invisible to /sbin/ifconfig. This
includes secondary addresses assigned to the same adapter without an alias
name, and causes issues with IPv4 as well.
Regards,
Daniel
--
✣ Daniel Pittman ✉ [email protected] ☎ +61 401 155 707
♽ made with 100 percent post-consumer electrons
--
You received this message because you are subscribed to the Google Groups
"Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-dev?hl=en.