1
0
mirror of https://github.com/krislamo/puppet-rsnapshot synced 2024-12-16 09:40:35 +00:00

Fix undefined variables

This commit is contained in:
Rune Juhl Jacobsen 2017-04-06 09:19:17 +02:00
parent 3821db2c4f
commit 450474165f
2 changed files with 4 additions and 3 deletions

View File

@ -12,8 +12,8 @@ class rsnapshot::config (
$conf_d = pick($rsnapshot::conf_d, $rsnapshot::params::conf_d, '/etc/rsnapshot') $conf_d = pick($rsnapshot::conf_d, $rsnapshot::params::conf_d, '/etc/rsnapshot')
$snapshot_root = pick($hosts['snapshot_root'], $rsnapshot::snapshot_root, '/backup') $snapshot_root = pick($hosts['snapshot_root'], $rsnapshot::snapshot_root, '/backup')
$logpath = pick($rsnapshot::logpath, $rsnapshot::params::config_logpath) $logpath = pick($rsnapshot::logpath, $rsnapshot::params::config_logpath)
$cronfile_prefix_use = pick($rsnapshot::cronfile_prefix_use, $rsnapshot::params::cronfile_prefix_use, false) $cronfile_prefix_use = pick($rsnapshot::cronfile_prefix_use, $rsnapshot::params::config_cronfile_prefix_use, false)
$cronfile_prefix = pick($rsnapshot::cronfile_prefix, $rsnapshot::params::cronfile_prefix, '') $cronfile_prefix = pick($rsnapshot::cronfile_prefix, $rsnapshot::params::config_cronfile_prefix, '')
# make sure lock path and conf path exist # make sure lock path and conf path exist
file { $conf_d: file { $conf_d:
ensure => 'directory', ensure => 'directory',
@ -82,7 +82,7 @@ class rsnapshot::config (
$rsync_numtries = pick_undef($hash['rsync_numtries'], $rsnapshot::params::config_rsync_numtries) $rsync_numtries = pick_undef($hash['rsync_numtries'], $rsnapshot::params::config_rsync_numtries)
#$backup_scripts = pick_undef($hash['backup_scripts'], $rsnapshot::params::config_backup_scripts) #$backup_scripts = pick_undef($hash['backup_scripts'], $rsnapshot::params::config_backup_scripts)
$snapshot_dir = "${config_snapshot_root}/${host}" $snapshot_dir = "${snapshot_root}/${host}"
$config = "${conf_d}/${host}.rsnapshot.conf" $config = "${conf_d}/${host}.rsnapshot.conf"
$lockfile = "${lockpath}/${host}.pid" $lockfile = "${lockpath}/${host}.pid"
$logfile = "${logpath}/${host}.log" $logfile = "${logpath}/${host}.log"

View File

@ -18,6 +18,7 @@ class rsnapshot (
$exclude = $rsnapshot::params::config_exclude, $exclude = $rsnapshot::params::config_exclude,
$snapshot_root = $rsnapshot::params::config_snapshot_root, $snapshot_root = $rsnapshot::params::config_snapshot_root,
$backup_levels = $rsnapshot::params::config_backup_levels, $backup_levels = $rsnapshot::params::config_backup_levels,
$backup_user = $rsnapshot::params::config_backup_user,
$cron_service_name = $rsnapshot::params::cron_service_name, $cron_service_name = $rsnapshot::params::cron_service_name,
$cronfile_prefix = $rsnapshot::params::config_cronfile_prefix, $cronfile_prefix = $rsnapshot::params::config_cronfile_prefix,
$cronfile_prefix_use = $rsnapshot::params::config_cronfile_prefix_use, $cronfile_prefix_use = $rsnapshot::params::config_cronfile_prefix_use,