X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=modules%2Fdebian-org%2Ftemplates%2Fdsa-puppet-stuff.cron.erb;h=a88d18147aa49e188a5b613dbbf547b3fcc2cc73;hb=1b33f950cfd4289185d8e3470dd0a3168c0782d8;hp=6bd13a131ddce1890a795dee586b658da958ca34;hpb=545beb1a8c528b96c44a803b60ac86c25c5674d9;p=dsa-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 6bd13a13..a88d1814 100644 --- a/modules/debian-org/templates/dsa-puppet-stuff.cron.erb +++ b/modules/debian-org/templates/dsa-puppet-stuff.cron.erb @@ -6,13 +6,12 @@ SHELL=/bin/bash @hourly root [ ! -d /var/cache/dsa ] || touch /var/cache/dsa/cron.alive <% if @lsbmajdistrelease <= '7' -%> -<% if scope.lookupvar('::hostname') == 'ball' -%> -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/bin/ruby1.9.1 /usr/sbin/puppetd -o --no-daemonize 2>&1 | egrep --text -v -f "$tmp"; rm -f "$tmp"; fi -<% else -%> 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 -<% end -%> <% else -%> 34 */4 * * * root if [ -x /usr/bin/puppet ]; 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/bin/puppet agent --onetime --no-daemonize 2>&1 | egrep --text -v -f "$tmp"; rm -f "$tmp"; fi <% end -%> @hourly root sleep $(( $RANDOM \% 300 )); if [ -x /usr/lib/nagios/plugins/dsa-check-stunnel-sanity ] && [ -e /etc/stunnel/puppet-ekeyd.conf ] && ! /usr/lib/nagios/plugins/dsa-check-stunnel-sanity > /dev/null && grep -q '^client = yes' /etc/stunnel/puppet-ekeyd.conf; then /usr/sbin/service stunnel4 restart > /dev/null; fi + +@daily munin-async [ -d /var/lib/munin-async ] && find /var/lib/munin-async -type f -mtime +90 -name '*.gz' -delete +@daily munin-async [ -d /var/lib/munin-async ] && find /var/lib/munin-async -type f -mtime +90 -size 0 -delete