Re: [Puppet Users] Problem with Variables and Class Inheritance

2010-03-25 Thread M.F Haris
Thanks Alan, Yesterday, I did it exactly the same way and it is running fine. I hope this will be helpful for other puppet newbies too. Am 24.03.2010 19:09, schrieb Alan Barrett: On Mon, 22 Mar 2010, Farooque M Haris wrote: class /*DevelopersManager */#Secondary Class 1 { *$fileList* = "d

Re: [Puppet Users] sharing variables between definitions

2010-03-25 Thread Michael Gliwinski
On Wednesday 24 Mar 2010 22:15:27 Michael DeHaan wrote: > On Wed, Mar 24, 2010 at 5:51 PM, Gustavo Soares wrote: > > Hi, Michael! thanks for your reply! > > > > actually it is the opposite.. :) i.e, I want to use the same variable, > > but in different definitions... > > Ok, sorry for the confusi

Re: [Puppet Users] sharing variables between definitions

2010-03-25 Thread Gustavo Soares
I have thought of using qualified variables, but i think that won't work inside a tempalte, right? Or can I do <%= class::variable %> ? And I guess that if I am using dynamic variables, once I include the it will be evaluated only once, right? Gus --- Original message --- From: Michael

[Puppet Users] Re: Failed to generate additional resources using 'eval_generate': end of file reached

2010-03-25 Thread DieterVDW
I'm also having this issue. Seems random. On the following run things seem to go ok. Seems like a bug to me? On Mar 15, 5:29 pm, Kent Rankin wrote: > We keep getting a variety of these from a random set during each Puppet run: > > Sat Mar 13 23:46:42 -0500 2010 //cups/File[/etc/cups] (err): Faile

Re: [Puppet Users] fileserver.conf possible bug

2010-03-25 Thread James Cammarata
On Wed, 24 Mar 2010 21:53:12 -0700 (PDT), chakkerz wrote: > Hello there > > I've just had someone point out to me that if i have a line in my /etc/ > puppet/fileserver.conf and it has a trailing space in an allow line, > for instance: > > [modules] > allow puppetclient.example.org > >

Re: [Puppet Users] sharing variables between definitions

2010-03-25 Thread Michael Gliwinski
On Thursday 25 Mar 2010 11:48:44 Gustavo Soares wrote: > I have thought of using qualified variables, but i think that won't work > inside a tempalte, right? Or can I do <%= class::variable %> ? It will but you have to use <%= scope.lookup('class::variable') %> (note, typing from memory, to be su

Re: [Puppet Users] sharing variables between definitions

2010-03-25 Thread Gustavo Soares
Hi, Michael, thank you for your reply. What I mean about "dynamic variables" is: let's say that I have a variable like *$log_path = "/var/log/$site" *to specify the log path for different applications that run on the same host. Thus, depending on the value of $site variable, the $log_path varia

Re: [Puppet Users] sharing variables between definitions

2010-03-25 Thread Gustavo Soares
well, forget what I said.. It seems that I have misunderstood the variable scope... I will try to do as you suggest. Thanks! On Thu, Mar 25, 2010 at 10:42 AM, Gustavo Soares wrote: > Hi, Michael, thank you for your reply. > > What I mean about "dynamic variables" is: > > let's say that I have

Re: [Puppet Users] sharing variables between definitions

2010-03-25 Thread Michael Gliwinski
Ah, yes, in this case putting it in a class wouldn't work. Well, obviously it wouldn't apply to all variables but in case of paths what I often to is split it, e.g. have $log_root = "/var/log" in the class and in the define do ${class::log_root}/${site}. On Thursday 25 Mar 2010 13:42:13 Gustav

Re: [Puppet Users] Re: Failed to generate additional resources using 'eval_generate': end of file reached

2010-03-25 Thread Disconnect
Ditto here, except since we're going through apache we get a huge query stream that starts with: Failed to generate additional resources using 'eval_generate': Error 502 on SERVER: 502 Proxy Error Proxy Error The proxy server received an invalid response from an upstream server. The proxy server

[Puppet Users] facter or ifconfig to find hosts with ip on certain subnet

2010-03-25 Thread deet
Hello. I'm running facter 1.5.7 and puppet 0.25.4. I'm trying to create a manifest that would identify if a host has an IP address in a certain subnet. If the host does have an IP in the specified subnet then some static route mangling would happen. The desired subnets don't align with a

Re: [Puppet Users] facter or ifconfig to find hosts with ip on certain subnet

2010-03-25 Thread Ashley Penney
I made a custom fact for something kind of similar to this: require 'facter' Facter.add("networklocation") do setcode do result = case Facter["ipaddress"].value when /10.241.209/: "209" else "" end result end end It's kind of horrible and