Allow specifying the threshold on the command line
This commit is contained in:
parent
875a961eba
commit
8257bd69e2
@ -8,7 +8,7 @@
|
||||
|
||||
rr="/var/run/reboot-required"
|
||||
# 604800 - 1 week in seconds
|
||||
threshold="604800"
|
||||
threshold="${1:-604800}"
|
||||
if [ -f "$rr" ]; then
|
||||
# We have a pending reboot; alert in different states depending on its age
|
||||
lastmod=$(date +%s -r "$rr")
|
||||
|
Loading…
Reference in New Issue
Block a user