X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=modules%2Fdebian_org%2Ftemplates%2Fdsa-puppet-stuff.cron.erb;h=71fe19f65d5cda11317e4955465a9b2abf560a4a;hb=923f1c61472c907e7e10ec74655fd93fb6bcb56a;hp=73679cfb6a778ad22bec5f4bb7c06b6247ddc998;hpb=e359026e3ec5d9b5726f3b1834e07c3d307c0a0e;p=mirror%2Fdsa-puppet.git diff --git a/modules/debian_org/templates/dsa-puppet-stuff.cron.erb b/modules/debian_org/templates/dsa-puppet-stuff.cron.erb index 73679cfb6..71fe19f65 100644 --- a/modules/debian_org/templates/dsa-puppet-stuff.cron.erb +++ b/modules/debian_org/templates/dsa-puppet-stuff.cron.erb @@ -1,4 +1,6 @@ +@hourly root [ ! -d /var/cache/dsa ] || touch /var/cache/dsa/cron.alive + <% if scope.call_function('versioncmp', [@puppetversion.to_s, '3.0.0']) <= 0 -%> 34 */4 * * * root if [ -x /usr/sbin/puppetd ]; then sleep $(( $RANDOM \% 7200 )); if [ -x /usr/bin/timeout ]; then TO="timeout --kill-after=900 3600"; else TO=""; fi; tmp="$(tempfile)"; egrep -v '^(#|$)' /etc/dsa/cron.ignore.dsa-puppet-stuff > "$tmp" && $TO /usr/sbin/puppetd -o --no-daemonize 2>&1 | egrep --text -v -f "$tmp"; rm -f "$tmp"; fi <% else -%> @@ -12,3 +14,8 @@ @daily root [ -d /var/lib/puppet/clientbucket ] && find /var/lib/puppet/clientbucket -type f -mtime +60 -delete && find /var/lib/puppet/clientbucket -type d -empty -delete @hourly root ! [ -x /usr/local/sbin/ntp-restart-if-required ] || /usr/local/sbin/ntp-restart-if-required + +# Nagios related entries +@hourly root [ -x /usr/sbin/dsa-update-apt-status ] && sleep $(( $RANDOM \% 1800 )) && /usr/sbin/dsa-update-apt-status 2>&1 | logger -t dsa-update-apt-status +13 */8 * * * root [ -x /usr/sbin/dsa-update-samhain-status ] && sleep $(( $RANDOM \% 27000 )) && /usr/sbin/dsa-update-samhain-status +40 12 25 * * root [ -x /usr/sbin/dsa-update-unowned-file-status ] && sleep $(( $RANDOM \% 86400 )) && /usr/sbin/dsa-update-unowned-file-status