diff options
Diffstat (limited to 'shutdownasap.conf.in')
-rwxr-xr-x | shutdownasap.conf.in | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/shutdownasap.conf.in b/shutdownasap.conf.in index 7558407..d42892c 100755 --- a/shutdownasap.conf.in +++ b/shutdownasap.conf.in @@ -30,10 +30,9 @@ beforeWatchHook() { true } -# hook to execute if we believe, the system should come down -# If this hook returns with 0, everything is ok - if it returns with 1, -# we should keep waiting for shutdown (and ask this hook again). -additionalWatchHook() { +# This hook should return != 0, if we should keep waiting for shutdown. +# Note, that it is queried often. +additionalWatchHookFast() { if command -v check-if-bareos-backup-is-running; then if ! sudo check-if-bareos-backup-is-running; then return 1 @@ -44,6 +43,12 @@ additionalWatchHook() { return 0 } +# This hook should return != 0, if we should keep waiting for shutdown. +# Note, that it is queried seldom (e.g. once, if it returns 0). +additionalWatchHookSlow() { + return 0 +} + # hook to execute before shutting down beforeShutDownHook() { if command -v doalogwatch >/dev/null; then |