On Monday, November 26, 2012 10:10:06 AM UTC-6, jcbollinger wrote: > > > > On Tuesday, November 20, 2012 3:32:07 PM UTC-6, llowder wrote: >> >> I was going through the open bugs and came across an interesting one[1], >> where if a node has a certain name, and includes a class of the same name, >> the class doesn't get loaded. >> >> I did discover a workaround - two of them, actually. >> >> However, I was somewhat curious. Is this something people do? >> > > > Some people do create "node classes", but as you can imagine, it doesn't > scale very well. Nevertheless, it shouldn't break. > > I wonder whether you can work around the issue by using the absolute name > of the class, like this: > > node 'centos' { > include '::centos' > } > > I have found 2 ways to get around this. The first is to use a wild card regex as the node name:
node /cento./{ include centos } And the other is to use paramater syntax, which works with "node centos" "node /centos/" and "node /cento./" > Likewise, I wonder whether you can work around the issue of referencing > class variables inside node blocks by referring to them via their absolute > names. > > > The class variables are only available in the node if the class itself gets loaded. I put together a set of tests that show the different combinations, you can see them at https://gist.github.com/4090041 > John > > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/Tg-1MWNlVSQJ. 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.