diff options
author | Gabriel Filion <lelutin@gmail.com> | 2013-01-02 12:56:08 -0500 |
---|---|---|
committer | Gabriel Filion <lelutin@gmail.com> | 2013-01-02 12:56:08 -0500 |
commit | 3772b3d71f1d5564ef211a0f33af0020b1a7a210 (patch) | |
tree | 732d280f6e237033c4d2d44743d9d2f7b50eb186 | |
parent | 560b7c829e8ec043cf603fd6b1e2a1d3e0946a63 (diff) |
Class hierarchy is off and passenger apt repository is always installed
also, the $puppet_majorversion variable was empty because it was not
fully qualified.
Signed-off-by: Gabriel Filion <lelutin@gmail.com>
-rw-r--r-- | manifests/puppetmaster/debian.pp | 7 | ||||
-rw-r--r-- | manifests/puppetmaster/package/base.pp | 4 | ||||
-rw-r--r-- | manifests/puppetmaster/package/debian.pp | 10 | ||||
-rw-r--r-- | manifests/puppetmaster/passenger.pp | 11 |
4 files changed, 18 insertions, 14 deletions
diff --git a/manifests/puppetmaster/debian.pp b/manifests/puppetmaster/debian.pp index fc24221..fbb3716 100644 --- a/manifests/puppetmaster/debian.pp +++ b/manifests/puppetmaster/debian.pp @@ -1,10 +1,9 @@ -class puppet::puppetmaster::debian { +class puppet::puppetmaster::debian inherits puppet::puppetmaster::linux { include puppet::puppetmaster::package - include puppet::puppetmaster::linux - + if $puppetmaster_mode != 'passenger' { - if $puppet_majorversion >= '2.6' { + if $puppet::base::puppet_majorversion >= '2.6' { Service['puppetmaster'] { hasstatus => true, hasrestart => true } } } diff --git a/manifests/puppetmaster/package/base.pp b/manifests/puppetmaster/package/base.pp index ff8d02a..ba557c4 100644 --- a/manifests/puppetmaster/package/base.pp +++ b/manifests/puppetmaster/package/base.pp @@ -1,4 +1,6 @@ -class puppet::puppetmaster::package::base inherits puppet::puppetmaster::package { +class puppet::puppetmaster::package::base inherits puppet::puppetmaster::linux { + + include puppet::puppetmaster::package package { 'puppetmaster': ensure => present, diff --git a/manifests/puppetmaster/package/debian.pp b/manifests/puppetmaster/package/debian.pp index cea7ac4..629d57b 100644 --- a/manifests/puppetmaster/package/debian.pp +++ b/manifests/puppetmaster/package/debian.pp @@ -1,13 +1,5 @@ class puppet::puppetmaster::package::debian { include puppet::puppetmaster::package::base - - apt::preferences_snippet { - 'puppet_passenger': - package => 'puppet*', - pin => "version $puppetmaster_ensure_version", - priority => 2000, - notify => Exec['refresh_apt'], - before => Package['puppetmaster']; - } + } diff --git a/manifests/puppetmaster/passenger.pp b/manifests/puppetmaster/passenger.pp index e026a62..3035509 100644 --- a/manifests/puppetmaster/passenger.pp +++ b/manifests/puppetmaster/passenger.pp @@ -16,6 +16,17 @@ class puppet::puppetmaster::passenger inherits puppet::puppetmaster::base { 'puppet:///modules/puppet/master/config.ru' ], owner => puppet, group => 0, mode => '0644'; } + + include apt + + apt::preferences_snippet { + 'puppet_passenger': + package => 'puppet*', + pin => "version $puppetmaster_ensure_version", + priority => 2000, + notify => Exec['refresh_apt'], + before => Package['puppetmaster']; + } } default: { file { |