Re: [Puppet Users] Template problems

2016-03-09 Thread Ugo Bellavance
On Tuesday, March 8, 2016 at 8:11:46 AM UTC-5, R.I. Pienaar wrote: > > > > - Original Message - > > From: "Ugo Bellavance" > > > To: "puppet-users" > > > Sent: Tuesday, 8 March, 2016 13:50:46 > > Subject: Re: [Puppet Users

Re: [Puppet Users] Template problems

2016-03-08 Thread R.I.Pienaar
- Original Message - > From: "Ugo Bellavance" > To: "puppet-users" > Sent: Tuesday, 8 March, 2016 13:50:46 > Subject: Re: [Puppet Users] Template problems > Just a thought, where should I have looked for that? Is it pure Ruby? yeah pretty much,

Re: [Puppet Users] Template problems

2016-03-08 Thread Ugo Bellavance
Just a thought, where should I have looked for that? Is it pure Ruby? On Tuesday, March 8, 2016 at 1:30:38 AM UTC-5, R.I. Pienaar wrote: > > You can't nest the <% %> inside another. Try: > > <%= if @rotatelogsuselink then "-L /var/log/httpd/#{@name}/access.log" end > %> > > Everything inside is

Re: [Puppet Users] Template problems

2016-03-08 Thread Ugo Bellavance
It works! You guys are better than most vendor's service contract! Thanks a lot! Ugo On Tuesday, March 8, 2016 at 1:30:38 AM UTC-5, R.I. Pienaar wrote: > > You can't nest the <% %> inside another. Try: > > <%= if @rotatelogsuselink then "-L /var/log/httpd/#{@name}/access.log" end > %> > > Ev

Re: [Puppet Users] Template problems

2016-03-07 Thread R.I.Pienaar
You can't nest the <% %> inside another. Try: <%= if @rotatelogsuselink then "-L /var/log/httpd/#{@name}/access.log" end %> Everything inside is normal Ruby and that's how interpolation works there --- R.I.Pienaar > On 8 Mar 2016, at 04:32, Ugo Bellavance wrote: > > > <%= if @rotatelogsuselin

[Puppet Users] Template problems

2016-03-07 Thread Ugo Bellavance
Hi, I'd like to be able to do something but I always get an error. Here is my code: <% if userotatelogs == false -%> CustomLog /var/log/httpd/<%= name %>/access.log combined <% else -%> CustomLog "|/usr/sbin/rotatelogs <%= if @rotatelogsuselocaltime then '-l' end %> <%= if @rotatelog