projects
/
mirror
/
dsa-puppet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ddb55bb
)
Run puppet sync with timeout(1) if it's installed
author
Peter Palfrader
<peter@palfrader.org>
Wed, 26 Aug 2009 08:43:23 +0000
(10:43 +0200)
committer
Peter Palfrader
<peter@palfrader.org>
Wed, 26 Aug 2009 08:43:23 +0000
(10:43 +0200)
files/etc/cron.d/dsa-puppet-stuff
patch
|
blob
|
history
diff --git
a/files/etc/cron.d/dsa-puppet-stuff
b/files/etc/cron.d/dsa-puppet-stuff
index
72724ee
..
f3aa1a5
100644
(file)
--- a/
files/etc/cron.d/dsa-puppet-stuff
+++ b/
files/etc/cron.d/dsa-puppet-stuff
@@
-1,3
+1,3
@@
SHELL=/bin/bash
@hourly root [ ! -d /var/cache/dsa ] || touch /var/cache/dsa/cron.alive
-34 */4 * * * root
[ ! -x /usr/sbin/puppetd ] || ( sleep $(( $RANDOM \% 3600 )) && /usr/sbin/puppetd --factsync -o --no-daemonize )
+34 */4 * * * root
if [ -x /usr/sbin/puppetd ]; then sleep $(( $RANDOM \% 3600 )); if [ -x /usr/bin/timeout ]; then TO="timeout 3600"; else TO=""; fi; $TO /usr/sbin/puppetd --factsync -o --no-daemonize ; fi