diff options
author | Olivier Blin <dev@blino.org> | 2015-11-20 01:02:05 +0100 |
---|---|---|
committer | Olivier Blin <dev@blino.org> | 2015-11-30 01:32:43 +0100 |
commit | 317b5a0eeab6738b86955c4ead15dc3b4bc0bcf6 (patch) | |
tree | d0b9fa01c7c57b1c1677e0484b83e70ad9e2a4eb | |
parent | 84c4810ad592c1260057b85630c07cad196d8671 (diff) | |
download | puppet-317b5a0eeab6738b86955c4ead15dc3b4bc0bcf6.tar puppet-317b5a0eeab6738b86955c4ead15dc3b4bc0bcf6.tar.gz puppet-317b5a0eeab6738b86955c4ead15dc3b4bc0bcf6.tar.bz2 puppet-317b5a0eeab6738b86955c4ead15dc3b4bc0bcf6.tar.xz puppet-317b5a0eeab6738b86955c4ead15dc3b4bc0bcf6.zip |
puppet: do not install ruby-hiera-puppet from Mageia >= 4
Only install it for older distros with puppet 2.7, since, since hiera
has been integrated from puppet 3 (Mageia 4).
-rw-r--r-- | modules/puppet/manifests/hiera.pp | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/modules/puppet/manifests/hiera.pp b/modules/puppet/manifests/hiera.pp index 8b692316..338b67e1 100644 --- a/modules/puppet/manifests/hiera.pp +++ b/modules/puppet/manifests/hiera.pp @@ -1,11 +1,17 @@ class puppet::hiera { - package { ['ruby-hiera','ruby-hiera-puppet']: } + package { ['ruby-hiera']: } - # ugly, remove once hiera is either fixed or integrated to puppet - file { '/etc/puppet/external/hiera': - ensure => link, - target => '/usr/lib/ruby/gems/1.8/gems/hiera-puppet-0.3.0/', - require => Package['ruby-hiera-puppet'], + if versioncmp($::lsbdistrelease, '4') < 0 { + package { ['ruby-hiera-puppet']: } + # ugly hack for puppet 2.7, since hiera has been integrated + # from puppet 3 only (Mageia 4) + file { '/etc/puppet/external/hiera': + ensure => link, + # this should be /usr/share/ruby/gems/gems/hiera-puppet-1.0.0 + # on Mageia 3, but we do not have any infra hosts running mga3 + target => '/usr/lib/ruby/gems/1.8/gems/hiera-puppet-0.3.0/', + require => Package['ruby-hiera-puppet'], + } } # ease the use fo the command line tool |