aboutsummaryrefslogtreecommitdiffstats
path: root/ansible/roles
diff options
context:
space:
mode:
authorGravatar Johannes Christ <[email protected]>2025-02-03 22:01:03 +0100
committerGravatar Johannes Christ <[email protected]>2025-02-03 22:01:03 +0100
commit5a61aae72d1985b2c58274e6416b627a1c2227c1 (patch)
tree986d2e9d3bee6713431e56dabb974407d5725492 /ansible/roles
parentHave Fredrick only reply to 25% of mailing list posts (diff)
Make Fredrick go for walks before replying to some e-mailsfredrick-time-to-reply
Diffstat (limited to 'ansible/roles')
-rw-r--r--ansible/roles/postfix/templates/services/fredrick-reply.sh.j23
1 files changed, 2 insertions, 1 deletions
diff --git a/ansible/roles/postfix/templates/services/fredrick-reply.sh.j2 b/ansible/roles/postfix/templates/services/fredrick-reply.sh.j2
index 609d37f..90ebe04 100644
--- a/ansible/roles/postfix/templates/services/fredrick-reply.sh.j2
+++ b/ansible/roles/postfix/templates/services/fredrick-reply.sh.j2
@@ -107,7 +107,8 @@ case $RECIPIENT in
at -q z -f "$ATSCRIPT" now + 1 min
;;
*)
- at -q z -f "$ATSCRIPT" now + 20 min
+ reply_delay=$(awk 'BEGIN { srand(); print (rand() * 100) + 20 }')
+ at -q z -f "$ATSCRIPT" now + "$reply_delay" min
;;
esac
rm "$ATSCRIPT"