summaryrefslogtreecommitdiff
path: root/manifests/master/cleanup_reports.pp
blob: 98cb81a3ea08af83cf5c1e5a91c7895611fa7cf8 (plain)
1
2
3
4
5
6
7
class puppet::master::cleanup_reports {
  # clean up reports older than $puppetmaster_cleanup_reports days
  file { '/etc/cron.daily/puppet_reports_cleanup.sh':
    content => "#!/bin/bash\nfind ${puppet::master::reports_dir} -maxdepth 2 -type f -ctime +${puppet::master::cleanup_reports} -exec rm {} \\;\n",
    owner => root, group => 0, mode => 0700;
  }
}