It doesn't seem to work from me, bombing out if the template specified first doesn't exist. you'd expect it to gracefully ignore and try the next...this a bug? running puppet-0.24.6-1.1
On Jul 23, 12:31 pm, Udo Waechter <udo.waech...@uni-osnabrueck.de> wrote: > hmmm, right after sending the provious mail, I realised something: > > On 23.07.2009, at 21:27, Udo Waechter wrote: > > > > > Hi, > > > On 23.07.2009, at 19:58, TomTom wrote: > > >> Is it possible to do the same thing with templates? > >> An example of what I want to do is: > > >> file { "/etc/sysctl.conf": > >> content => [ > >> template("sysctl.conf.$hostname.erb"), > >> template("sysctl.conf.$tuningpolicy.erb"), > >> template("sysctl.conf.erb"), > >> ] > >> } > > > Unfortunately, the behaviour here is different. All templates > > outputs are concatenated... > > > see:http://reductivelabs.com/trac/puppet/wiki/FunctionReference#template > > this is different call: > > file{"/foo/bar": > content => template("template1","template2") > > } > > yields concatenated templates. > > maybe this: > file { "/etc/sysctl.conf": > content => [ > template("sysctl.conf.$hostname.erb"), > template("sysctl.conf.$tuningpolicy.erb"), > template("sysctl.conf.erb"), > ] > > } > > works as expected, namely to select the one template that exists (or > the first that exists). > > dunno, > udo. > > -- > :: udo waechter - r...@zoide.net :: N 52º16'30.5" E 8º3'10.1" > :: genuine input for your ears:http://auriculabovinari.de > :: your eyes:http://ezag.zoide.net > :: your brain:http://zoide.net > > smime.p7s > 2KViewDownload --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Users" group. 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 -~----------~----~----~----~------~----~------~--~---