On Thursday, January 26, 2012 11:24:19 AM UTC-6, Gary Larizza wrote:
>
>
>
> On Thu, Jan 26, 2012 at 7:55 AM, Alexander Swen  wrote:
>
>> hi,
>>
>> in the logs of our 2.7.10 puppet master we find messages like these:
>> Dynamic lookup of $functie at /etc/puppet/manifests/server_classes.pp:52 
>> is deprecated. Support will be removed in Puppet 2.8. Use a fully-qualified 
>> variable name (e.g., $classname::variable) or parameterized classes.
>>
>> However, I'm a bit worried that a key functionality will be removed in 
>> 2.8: we set a param/value in every node telling the node what it's funtion 
>> is and use that in a variety of manifests to decide how to configure the 
>> server.
>>
>> we use something like:
>> node servera {
>>   $function = 'webserver'
>>   include function_dependent_services
>> }
>> node serverb {
>>   $function = 'dbserver'
>>   include function_dependent_services
>> }
>>
>> class function_dependent_services {
>>   include iptables
>>   include motd
>> }
>>
>> class iptables {
>>   file {
>>    "/etc/iptables/cfg-firewall":
>>      content => template("iptables/cfg-firewall.erb");
>>   }
>> }
>>
>> and then, somewhere in the erb we evaluate <%= function %>
>>
>> will this be broken in 2.8?
>> and, if yes: how should we tell the erb the param that changes for a lot 
>> of nodes?
>>
>> or should I file this as a bug for v2.8?
>>
>> please help us out, thanks in advance
>> Alex
>
>
> Hi Alex,
>
> We have a page on our website that should help you out with this --> 
> http://docs.puppetlabs.com/guides/scope_and_puppet.html  Have you seen 
> that yet?  That's a great place to start.  You have parameterized classes 
> that can help you out, as well as data lookup methods like Hiera (
> http://github.com/puppetlabs/hiera) that are also available.  
>
>   
Alex, how did you end up solving this? Please post back to the list. I have 
exactly the same problem with my upgrade to puppet 2.7. I have variables 
defined in my nodes that are used in my templates and want to do this 
correctly so that the upgrade to puppet 2.8 works.

Thanks.
 
 

-- 
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/-/C9V5yl4Z2UQJ.
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.

Reply via email to