aboutsummaryrefslogtreecommitdiff
path: root/templates/rdiff.conf.erb
diff options
context:
space:
mode:
Diffstat (limited to 'templates/rdiff.conf.erb')
-rw-r--r--templates/rdiff.conf.erb10
1 files changed, 10 insertions, 0 deletions
diff --git a/templates/rdiff.conf.erb b/templates/rdiff.conf.erb
index 23c336f..c948c2d 100644
--- a/templates/rdiff.conf.erb
+++ b/templates/rdiff.conf.erb
@@ -10,6 +10,16 @@
[source]
type = local
<%= 'keep = ' + keep if keep %>
+<% if stagger -%>
+when = everyday at 1:<%= i = 0
+ total = 0
+ until i == hostname.length
+ total += (hostname[i] - 96) / (2.9 * (10 ** (i + 1)))
+ total += (hostname[i] - 96) / (27.0 ** (i+1))
+ i += 1
+ end
+ (total*60).to_i %>
+<% end -%>
<% if include.is_a? String -%>
<%= 'include = ' + include %>