mirror of
https://github.com/plantroon/acme.sh.git
synced 2024-12-22 21:21:42 +00:00
random minute
This commit is contained in:
parent
a8ab028b84
commit
32b3717c32
7
acme.sh
7
acme.sh
@ -3371,15 +3371,18 @@ installcronjob() {
|
|||||||
_err "Can not install cronjob, $PROJECT_ENTRY not found."
|
_err "Can not install cronjob, $PROJECT_ENTRY not found."
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
_t=$(_time)
|
||||||
|
random_minute=$(_math $_t % 60)
|
||||||
if _exists uname && uname -a | grep SunOS >/dev/null; then
|
if _exists uname && uname -a | grep SunOS >/dev/null; then
|
||||||
crontab -l | {
|
crontab -l | {
|
||||||
cat
|
cat
|
||||||
echo "0 0 * * * $lesh --cron --home \"$LE_WORKING_DIR\" > /dev/null"
|
echo "$random_minute 0 * * * $lesh --cron --home \"$LE_WORKING_DIR\" > /dev/null"
|
||||||
} | crontab --
|
} | crontab --
|
||||||
else
|
else
|
||||||
crontab -l | {
|
crontab -l | {
|
||||||
cat
|
cat
|
||||||
echo "0 0 * * * $lesh --cron --home \"$LE_WORKING_DIR\" > /dev/null"
|
echo "$random_minute 0 * * * $lesh --cron --home \"$LE_WORKING_DIR\" > /dev/null"
|
||||||
} | crontab -
|
} | crontab -
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user