summaryrefslogtreecommitdiff
path: root/manifests/client
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2010-12-10 16:35:10 -0500
committerMicah Anderson <micah@riseup.net>2010-12-10 16:35:10 -0500
commitfefc399e7e28ec871d91089d535073c2bc705009 (patch)
tree32c9660134857b9c82189db973467cb039238747 /manifests/client
parent882bef6995352dd125b58ebbdadaddbd88121120 (diff)
this change makes sure that munin-common is installed before munin-node is installed on Debian systems that are not lenny (would be nice if we could use operators for lsbdistcode name like 'if $lsbdistcodename >> "lenny")
on Debian Squeeze and later, the munin-node package requires that munin-common be installed. this would normally be handled automatically by the packaging system, but if you utilize the $munin_node_ensure_version variable to set it to the backports version, and you have backports pinned properly (as the shared-apt module does it), it will fail to install the munin-common package from backports. you would think that this change should go in the debian.pp, but that is not possible because debian.pp inherits client/package.pp and thus the order happens wrong
Diffstat (limited to 'manifests/client')
-rw-r--r--manifests/client/package.pp14
1 files changed, 14 insertions, 0 deletions
diff --git a/manifests/client/package.pp b/manifests/client/package.pp
index 0fc3529..921d996 100644
--- a/manifests/client/package.pp
+++ b/manifests/client/package.pp
@@ -2,10 +2,24 @@ class munin::client::package inherits munin::client::base {
if $munin_node_ensure_version == '' { $munin_node_ensure_version = 'installed' }
+ if $operatingsystem == "Debian" and $lsbdistcodename != "lenny" {
+ package { 'munin-common':
+ before => Package['munin-node'],
+ ensure => $munin_node_ensure_version;
+ }
+
+ Package['munin-node']{
+ require => Package['munin-common'],
+ }
+ }
+
+
package { 'munin-node': ensure => $munin_node_ensure_version }
+
Service['munin-node']{
require => Package[munin-node],
}
+
File['/etc/munin/munin-node.conf']{
# this has to be installed before the package, so the postinst can
# boot the munin-node without failure!