On 2014-05-13 16:34, Viktor Jevdokimov wrote:
On some CentOS servers we started to receive an error:

Fact resolution fact='env', resolution='<anonymous>' resolved to an
invalid value: Expected prod to be one of [Integer, Float, TrueClass,
FalseClass, NilClass, String, Array, Hash], but was Symbol

Welcome to facter 2.0

Custom fact script:

Facter.add('env') do
 setcode do
 case Facter.value(:ipaddress)
 when /^172.22.1.*$/
 :dev
 when /^10.1.2.*$/

 :prod
 else

 :default
 end
 end
end


change all :XXXX to "XXXX"


Regards, David

--
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/eed613ba03f0563d641f92386f19c33e%40hosting.edv-bus.at.
For more options, visit https://groups.google.com/d/optout.

Reply via email to