Here is a snipit from our debian.pp that is inherited on everyone of our Ubuntu systems. file { "main.cf": path => "/etc/postfix/main.cf", owner => root, group => root, mode => 644, content => template("main.cf.erb"); } My problem is arising when I try to override main.cf in a host specific file call host_drkatz.pp with this snipit. class drkatz_postfix inherits debian { File["main.cf"] { path => "/etc/postfix/main.cf", owner => root, group => root, mode => 644, source => "puppet://puppet/private/etc/postfix/main.cf" } } The error that is received from the client is ''err: Could not create main.cf: You cannot specify more than one of content, source, target at /etc/puppet/manifests/debian.pp:66 err: You cannot specify more than one of content, source, target at / etc/puppet/manifests/debian.pp:66'' Any insight on where our inheritance is getting mixed up would be a great help. Thank You. ---------------------------------------------------- Cody Herriges - Lead Unix System Administrator Maseeh College of Engineering and Computer Science Portland State University - Phone: (503)725-5497 Email: ody@cat.pdx.edu/support@cat.pdx.edu --~--~---------~--~----~------------~-------~--~----~ 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-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
On Jun 2, 2008, at 5:44 PM, Cody wrote:> The error that is received from the client is > > ''err: Could not create main.cf: You cannot specify more than one of > content, source, target at /etc/puppet/manifests/debian.pp:66 > err: You cannot specify more than one of content, source, target at / > etc/puppet/manifests/debian.pp:66'' > > Any insight on where our inheritance is getting mixed up would be a > great help.Set ''content => undef'' in the subclass, so the content value is removed and the source is added. Or, of course, use a template in both the base and subclass, so the content is being directly overridden. -- A gentleman is a man who can play the accordion but doesn''t. --Unknown --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com --~--~---------~--~----~------------~-------~--~----~ 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-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
When you do the override, set content => undef; --Paul On Mon, Jun 2, 2008 at 5:44 PM, Cody <c.a.herriges@gmail.com> wrote:> > Here is a snipit from our debian.pp that is inherited on everyone of > our Ubuntu systems. > > file { > "main.cf": > path => "/etc/postfix/main.cf", > owner => root, > group => root, > mode => 644, > content => template("main.cf.erb"); > } > > My problem is arising when I try to override main.cf in a host > specific file call host_drkatz.pp with this snipit. > > class drkatz_postfix inherits debian { > File["main.cf"] { > path => "/etc/postfix/main.cf", > owner => root, > group => root, > mode => 644, > source => "puppet://puppet/private/etc/postfix/main.cf" > } > } > > The error that is received from the client is > > ''err: Could not create main.cf: You cannot specify more than one of > content, source, target at /etc/puppet/manifests/debian.pp:66 > err: You cannot specify more than one of content, source, target at / > etc/puppet/manifests/debian.pp:66'' > > Any insight on where our inheritance is getting mixed up would be a > great help. > > Thank You. > > ---------------------------------------------------- > Cody Herriges - Lead Unix System Administrator > Maseeh College of Engineering and Computer Science > Portland State University - Phone: (503)725-5497 > Email: ody@cat.pdx.edu/support@cat.pdx.edu > > > >--~--~---------~--~----~------------~-------~--~----~ 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-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---
Ty, that was a very simple oversight. --~--~---------~--~----~------------~-------~--~----~ 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-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en -~----------~----~----~----~------~----~------~--~---