In regard to: Re: [Puppet Users] Dynamic Lookup of facter variable., Nigel...:
On Sun, Aug 19, 2012 at 8:00 PM, Douglas Garstang
<doug.garst...@gmail.com> wrote:
Oh god that's ugly.
Yes it is, and it was an unwitting bug with the deprecation warning
that is resolved in later versions.
Facts were supposed to be able to be referenced as $factname without
throwing the deprecation warning in your release, it's been fixed in
later versions.
Can you expound on this, Nigel?
Are you saying that we do *not* need to reference facts as $::factname
in all our classes, not even in preparation for puppet 3.x? What if
we *are* referencing them that way, now?
Tim
On Sun, Aug 19, 2012 at 7:48 PM, Eric Shamow <e...@puppetlabs.com> wrote:
Facts exist at top scope, as indicated in the scoping doc several people have
referred you to on this list. Use $::ec2_instance_type
Sent from my iPad
On Aug 19, 2012, at 10:44 PM, Douglas Garstang <doug.garst...@gmail.com> wrote:
I don't get it...
if ! ( $ec2_instance_type in [$ec2_inst_type_allow]) {
notice("NOT ALLOWED")
} else {
notice("ALLOWED")
}
2012-08-20T02:39:10.537134+00:00 truth puppet-master[24080]: Dynamic
lookup of $ec2_instance_type at /truth/sauce/env/prod/modules/rol
e/manifests/validate_server.pp:12 is deprecated. Support will be
removed in Puppet 2.8. Use a fully-qualified variable name (e.g., $
classname::variable) or parameterized classes.
Line 12 is the if statement. However, on the same client system...
[us1:i-16c5c050] root@testweb11:~# facter | grep ec2_instance_type
ec2_instance_type => m1.large
It's a facter variable. What's it complaining about?
--
Tim Mooney tim.moo...@ndsu.edu
Enterprise Computing & Infrastructure 701-231-1076 (Voice)
Room 242-J6, IACC Building 701-231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164
--
You received this message because you are subscribed to the Google Groups "Puppet
Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.