From 1e27b543c8175a501ee61222797be30b949f1ad3 Mon Sep 17 00:00:00 2001 From: Jerome Charaoui Date: Wed, 12 May 2010 16:28:46 -0400 Subject: depend on cron module --- manifests/linux.pp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'manifests/linux.pp') diff --git a/manifests/linux.pp b/manifests/linux.pp index 4190b85..3a79e34 100644 --- a/manifests/linux.pp +++ b/manifests/linux.pp @@ -24,11 +24,12 @@ class puppet::linux inherits puppet::base { require => Package[puppet], } + include cron file{'/etc/cron.d/puppetd.cron': source => [ "puppet://$server/modules/puppet/cron.d/puppetd.${operatingsystem}", "puppet://$server/modules/puppet/cron.d/puppetd" ], owner => root, group => 0, mode => 0644, - notify => service["crond"]; + notify => service["cron"]; } } -- cgit v1.2.3 From 04f62c810f14599fb935dee962689b2727d54c36 Mon Sep 17 00:00:00 2001 From: Jerome Charaoui Date: Wed, 12 May 2010 16:47:29 -0400 Subject: rename $puppet_version and $facter_version and default to installed instead of present --- manifests/linux.pp | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) (limited to 'manifests/linux.pp') diff --git a/manifests/linux.pp b/manifests/linux.pp index 3a79e34..f367f83 100644 --- a/manifests/linux.pp +++ b/manifests/linux.pp @@ -1,21 +1,13 @@ class puppet::linux inherits puppet::base { - $real_puppet_version = $puppet_version ? { - '' => 'present', - default => $puppet_version, - } - - $real_facter_version = $facter_version ? { - '' => 'present', - default => $facter_version, - } - + if $puppet_ensure_version == '' { $puppet_ensure_version = 'installed' } package{ 'puppet': - ensure => $real_puppet_version, + ensure => $puppet_ensure_version, } - + + if $facter_ensure_version == '' { $facter_ensure_version = 'installed' } package{ 'facter': - ensure => $real_facter_version, + ensure => $facter_ensure_version, } # package bc needed for cron -- cgit v1.2.3 From 834f6a89287a2d26e20fe57946fe0bf31909daa1 Mon Sep 17 00:00:00 2001 From: Jerome Charaoui Date: Wed, 12 May 2010 17:09:17 -0400 Subject: correct typo (do we really need to notify cron?) --- manifests/linux.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'manifests/linux.pp') diff --git a/manifests/linux.pp b/manifests/linux.pp index f367f83..ebbedcb 100644 --- a/manifests/linux.pp +++ b/manifests/linux.pp @@ -22,6 +22,6 @@ class puppet::linux inherits puppet::base { source => [ "puppet://$server/modules/puppet/cron.d/puppetd.${operatingsystem}", "puppet://$server/modules/puppet/cron.d/puppetd" ], owner => root, group => 0, mode => 0644, - notify => service["cron"]; + notify => Service['cron']; } } -- cgit v1.2.3 From 79cc286c7249e39f633f422390b5ab79d72f89dd Mon Sep 17 00:00:00 2001 From: Jerome Charaoui Date: Thu, 13 May 2010 10:14:53 -0400 Subject: fix include namespaces --- manifests/linux.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'manifests/linux.pp') diff --git a/manifests/linux.pp b/manifests/linux.pp index ebbedcb..f9e2ea6 100644 --- a/manifests/linux.pp +++ b/manifests/linux.pp @@ -10,13 +10,13 @@ class puppet::linux inherits puppet::base { ensure => $facter_ensure_version, } - # package bc needed for cron + # package bc needed for cron job include bc Service['puppet']{ require => Package[puppet], } - include cron + include ::cron file{'/etc/cron.d/puppetd.cron': source => [ "puppet://$server/modules/puppet/cron.d/puppetd.${operatingsystem}", -- cgit v1.2.3