mirror of
https://github.com/krislamo/puppet-rsnapshot
synced 2024-11-10 00:00:35 +00:00
Add option to avoid managing cron
This commit is contained in:
parent
450474165f
commit
d2cf15621b
@ -20,6 +20,7 @@ class rsnapshot (
|
||||
$backup_levels = $rsnapshot::params::config_backup_levels,
|
||||
$backup_user = $rsnapshot::params::config_backup_user,
|
||||
$cron_service_name = $rsnapshot::params::cron_service_name,
|
||||
$manage_cron = $rsnapshot::params::manage_cron,
|
||||
$cronfile_prefix = $rsnapshot::params::config_cronfile_prefix,
|
||||
$cronfile_prefix_use = $rsnapshot::params::config_cronfile_prefix_use,
|
||||
$check_mk_job = $rsnapshot::params::config_check_mk_job,
|
||||
|
@ -12,6 +12,7 @@ class rsnapshot::params {
|
||||
'Debian' => 'cron',
|
||||
default => '',
|
||||
}
|
||||
$manage_cron = true
|
||||
$cron_dir = '/etc/cron.d'
|
||||
$config_backup_levels = [ 'daily', 'weekly', 'monthly' ]
|
||||
$config_backup_defaults = true
|
||||
|
@ -1,10 +1,13 @@
|
||||
# == Class: rsnapshot::service
|
||||
#
|
||||
# Reloads cron
|
||||
class rsnapshot::service {
|
||||
service { $rsnapshot::cron_service_name:
|
||||
ensure => running,
|
||||
# Reloads cron
|
||||
class rsnapshot::service (
|
||||
$manage_cron = $rsnapshot::manage_cron
|
||||
) {
|
||||
|
||||
if $manage_cron {
|
||||
service { $rsnapshot::cron_service_name:
|
||||
ensure => running,
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user