diff options
author | Daniel Friesel <derf@finalrewind.org> | 2014-05-12 18:38:59 +0200 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2014-05-12 18:38:59 +0200 |
commit | 946f94e5c27d2b066243ad80579228fad34e1b17 (patch) | |
tree | 246aef35df9900ab9205e094454dfa0077615ba0 | |
parent | f202238c50aefa8935e883ca143dd2236f7c744d (diff) |
support --force-recheck with single host arguments (no services)
-rw-r--r-- | Changelog | 2 | ||||
-rwxr-xr-x | bin/icli | 10 |
2 files changed, 12 insertions, 0 deletions
@@ -5,6 +5,8 @@ git HEAD (perl Build.PL --icli-xyz-file=..., see README) * Do not throw warnings when encountering empty contact groups * Do not require --recheck when using --force-recheck + * Support --force-recheck with a host-only argument to immediately recheck + all services on a host icli 0.46 - Sun Sep 29 2013 @@ -883,6 +883,13 @@ sub recheck_service { say "Scheduled check of '$service' on '$host'"; } +sub force_recheck_host_all { + my ($host) = @_; + + dispatch_command( 'SCHEDULE_FORCED_HOST_SVC_CHECKS', $host, time() ); + say "Scheduled forced check of * on '$host'"; +} + sub force_recheck_service { my ( $host, $service ) = @_; @@ -904,6 +911,9 @@ sub action_on_host { if ($recheck) { recheck_host_all($h); } + elsif ($force_recheck) { + force_recheck_host_all($h); + } } sub action_on_service { |