summaryrefslogtreecommitdiff
path: root/manifests/cron/base.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/cron/base.pp')
-rw-r--r--manifests/cron/base.pp46
1 files changed, 22 insertions, 24 deletions
diff --git a/manifests/cron/base.pp b/manifests/cron/base.pp
index 7b40da6..7daa6fb 100644
--- a/manifests/cron/base.pp
+++ b/manifests/cron/base.pp
@@ -1,34 +1,32 @@
# manifests/cron/base.pp
class puppet::cron::base inherits puppet::base {
-
- case $operatingsystem {
- debian: { if $lsbdistcodename != 'lenny' { $stop_service = true } else { $stop_service = false } }
- openbsd, ubuntu: { $stop_service = false }
- default: { $stop_service = true }
- }
-
+
Service['puppet']{
enable => false,
}
- if $stop_service == true {
- $puppet_majorversion = regsubst($puppetversion,'^(\d+\.\d+).*$','\1')
- if $puppet_majorversion == '2.6' {
- Service['puppet']{
- ensure => stopped,
- }
- } else {
- Service['puppet']{
- hasstatus => false,
- pattern => 'puppetd',
- }
- # this works only on < 2.6
- exec { 'stop_puppet':
- command => 'kill `cat /var/run/puppet/puppetd.pid`',
- onlyif => 'test -f /var/run/puppet/puppetd.pid',
- require => Service['puppet'],
+ case $operatingsystem {
+ debian,openbsd,ubuntu: {
+ #it's already disabled
+ }
+ default: {
+ $puppet_majorversion = regsubst($puppetversion,'^(\d+\.\d+).*$','\1')
+ if $puppet_majorversion == '2.6' {
+ Service['puppet']{
+ ensure => stopped,
+ }
+ } else {
+ Service['puppet']{
+ hasstatus => false,
+ pattern => 'puppetd',
+ }
+ # this works only on < 2.6
+ exec { 'stop_puppet':
+ command => 'kill `cat /var/run/puppet/puppetd.pid`',
+ onlyif => 'test -f /var/run/puppet/puppetd.pid',
+ require => Service['puppet'],
+ }
}
}
}
}
-