From 3401e82c802d5d542edd15c308126c6892b5c356 Mon Sep 17 00:00:00 2001 From: Francois Deppierraz Date: Mon, 9 Mar 2009 15:45:19 +0100 Subject: Change the structure of this module --- manifests/classes/augeas.pp | 36 +++++++++++++++++++++--------------- 1 file changed, 21 insertions(+), 15 deletions(-) (limited to 'manifests/classes') diff --git a/manifests/classes/augeas.pp b/manifests/classes/augeas.pp index a093905..6c6f08f 100644 --- a/manifests/classes/augeas.pp +++ b/manifests/classes/augeas.pp @@ -1,22 +1,28 @@ -class augeas::base { - +class augeas { case $operatingsystem { - RedHat: { - package { - ["augeas", "augeas-libs", "ruby-augeas"]: - ensure => "present"; - } - } - - Debian, Ubuntu: { - package { - ["augeas-lenses", "libaugeas0", "augeas-tools", "libaugeas-ruby1.8"]: - ensure => "present"; - } - } + redhat: { include augeas::redhat } + debian: { include augeas::debian } + ubuntu: { include augeas::debian } + default: { include augeas::base } } +} +class augeas::base { file {"/usr/share/augeas/lenses/contrib": ensure => directory, } } + +class augeas::redhat inherits augeas::base { + package { + ["augeas", "augeas-libs", "ruby-augeas"]: + ensure => "present"; + } +} + +class augeas::debian inherits augeas::base { + package { + ["augeas-lenses", "libaugeas0", "augeas-tools", "libaugeas-ruby1.8"]: + ensure => "present"; + } +} -- cgit v1.2.3