I've been banging my head on this all day, and I cannot seem to figure out how to do it.

I have a package for Apache HTTPd. I want to be able to specify the exact version of the package to use for a particular installation. And it is also possible that I want to have two separate modules install the same package.

So, what I end up with is the following

class app-apache {
  package { "apache" : ensure => installed, noop => true }
}

class app-apache-server1 inherits app-apache {
   Package["apache"] {ensure => "2.2.15", noop => false}
}

class app-apache-server2 inherits app-apache {
   Package["apache"] {ensure => "2.2.15", noop => false}
}

Basically, I have two servers configured. Now, it is possible that both servers could end up on the same host, depending upon a number of facters. When that happens, I get an error about not being able to override the "ensure" method in app-apache-server2 because it was already overridden in app-apache-server1.

Anyone have any ideas on how to do this? I need to be able to specify the version I want for a particular class, and that can change from class to class. I realize that if two different classes define two different versions and both classes end up on the same node, I will get errors from YUM. I'm ok with that.

Marc Zampetti


--
You received this message because you are subscribed to the Google Groups "Puppet 
Users" group.
To post to this group, send email to puppet-us...@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.

Reply via email to