#TODO: to catch if $::apt_update_last_success has the value of -1 here. If we
#opt to do this, a info/warn would likely be all you'd need likely to happen
#on the first run, but if it's not run in awhile something is likely borked
#TODO: to catch if $::apt_update_last_success has the value of -1 here. If we
#opt to do this, a info/warn would likely be all you'd need likely to happen
#on the first run, but if it's not run in awhile something is likely borked
#if we should kick apt_update.
$daily_threshold = (strftime('%s') - 86400)
if $::apt_update_last_success {
#if we should kick apt_update.
$daily_threshold = (strftime('%s') - 86400)
if $::apt_update_last_success {
#if we should kick apt_update.
$weekly_threshold = (strftime('%s') - 604800)
if $::apt_update_last_success {
#if we should kick apt_update.
$weekly_threshold = (strftime('%s') - 604800)
if $::apt_update_last_success {
logoutput => 'on_failure',
refreshonly => $_refresh,
timeout => $::apt::_update['timeout'],
logoutput => 'on_failure',
refreshonly => $_refresh,
timeout => $::apt::_update['timeout'],