Skip to content

Commit

Permalink
cron deferable-reboot execute at random times
Browse files Browse the repository at this point in the history
  • Loading branch information
ilario committed Dec 2, 2024
1 parent 93a15d8 commit 20be3bf
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ unique_append()
}

unique_append \
"*/3 * * * * ((if ping -c 10 -W 10 \$(uci -q get lime-autogen.system.deferable_reboot_ping_target) &> /dev/null; then awk '{print \$1 + 1800}' /proc/uptime > /tmp/deferable-reboot.defer ; fi )&) "\
"*/3 * * * * ((sleep $((RANDOM % 120)); if ping -c 10 -W 10 \$(uci -q get lime-autogen.system.deferable_reboot_ping_target) &> /dev/null; then awk '{print \$1 + 1800}' /proc/uptime > /tmp/deferable-reboot.defer ; fi )&) "\
/etc/crontabs/root

0 comments on commit 20be3bf

Please sign in to comment.