I have a ruby custom fact that when queried with 'facter -p mysite' 
displays as expected (eg TX), but if I do 'facter -p | grep mysite' it 
shows up like ["MN"]. It will show up this wrong way when it goes to 
puppetdb (whose data I view with puppetboard).

This custom fact only behaves this way on one platform, AIX with 
ruby 2.0.0p353. The built-in facts do not have this same issue. Any ideas 
on how to fix this? The ruby fact code is something like:

Facter.add("mysite") do
    setcode do
        case Facter.value(:ipaddress)
            when /^10\.1\.91\.|^10\.1\.92\.|^10\.1\.93\./
                "TX"
            when /^13\.1\.1\.|^13\.1\.2\./
                "CA"
        end
    end
end

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/be893da1-8c15-4b52-b829-93bae51504ff%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to