-
Russ Allbery authored
The acceptable runtime for tmpreaper (used by base::tmpclean on Debian and Ubuntu) has been extended to 20 minutes globally, and the base::tmpclean::longer class, which existed only to do that, has been removed as unnecessary. The longer runtime limit should not pose a problem on any system. Clean up formatting and comments for installed files and Puppet manifests.
Russ Allbery authoredThe acceptable runtime for tmpreaper (used by base::tmpclean on Debian and Ubuntu) has been extended to 20 minutes globally, and the base::tmpclean::longer class, which existed only to do that, has been removed as unnecessary. The longer runtime limit should not pose a problem on any system. Clean up formatting and comments for installed files and Puppet manifests.
tmpclean.pp 803 B
# Configures a package that cleans out temporary files periodically.
#
# Debian and Ubuntu use tmpreaper. Red Hat uses tmpwatch. Both do roughly
# the same thing: run daily and clean out old files in /tmp that aren't being
# used.
#
# Note that Debian only cleans /tmp, not /var/tmp. Red Hat cleans both, but
# clears /var/tmp on a longer schedule.
class base::tmpclean {
case $::operatingsystem {
'debian', 'ubuntu': {
package { 'tmpreaper': ensure => present }
file { '/etc/tmpreaper.conf':
source => 'puppet:///modules/base/tmpclean/etc/tmpreaper.conf',
}
}
'redhat': {
package { 'tmpwatch': ensure => present }
file { '/etc/cron.daily/tmpwatch':
source => 'puppet:///modules/base/tmpclean/etc/cron.daily/tmpwatch',
}
}
}
}