Re: [Puppet Users] facter values in upper case

2010-05-28 Thread Adam Winberg
way to make it work: $my_type = "$type" $my_type = inline_template("<%= my_type.upcase %>") notify { "type is set to $my_type":; } thanks for your help! //Adam On 28 May 2010 13:47, Daniel Pittman wrote: > Ohad Levy writes: > > > you are right, it seems that type is a reserved word in ruby

Re: [Puppet Users] facter values in upper case

2010-05-28 Thread Daniel Pittman
Ohad Levy writes: > you are right, it seems that type is a reserved word in ruby :( Just don't try using the variable 'fork' in your templates. ;) > using another variable name should work. Theoretically you might be able to use a lookup function to get the value, but practically it is (sadly)

Re: [Puppet Users] facter values in upper case

2010-05-28 Thread Ohad Levy
you are right, it seems that type is a reserved word in ruby :( using another variable name should work. I'll play and see if I can come up with something On Fri, May 28, 2010 at 4:13 PM, Adam Winberg wrote: > ok, interesting! > > however i cant make it work: > > $my_type = inline_template("<%=

Re: [Puppet Users] facter values in upper case

2010-05-28 Thread Adam Winberg
ok, interesting! however i cant make it work: $my_type = inline_template("<%= type.upcase %>") notify { "type is set to $my_type":; } and log output on client: puppetd[13739]: type is set to Notebook i was expecting to see "NOTEBOOK" there, but no luck. I'm new to puppet and my ruby is rubbish

Re: [Puppet Users] facter values in upper case

2010-05-27 Thread Ohad Levy
you can use inline_template to sanitize your values.. e.g.: $my_type = inline_template("<%= type.upcase %> Ohad On Fri, May 28, 2010 at 2:44 PM, Adam Winberg wrote: > Hi, > > facter variables typically have values in lower case. We are looking > into moving to puppet for our config administrati

[Puppet Users] facter values in upper case

2010-05-27 Thread Adam Winberg
Hi, facter variables typically have values in lower case. We are looking into moving to puppet for our config administration and are currently using a system where we do file name matching dependent on specific suffixes - for example a file named "*--LAPTOP" will only be deployed on machines tagge