diff options
author | makkalot <makkalot@gmail.com> | 2008-08-08 18:32:52 +0300 |
---|---|---|
committer | makkalot <makkalot@gmail.com> | 2008-08-08 18:32:52 +0300 |
commit | 107648ae12cf37cd349f01bd7cb44b7b0584344d (patch) | |
tree | e1818b8fea95ef4b4bb547eb081ddf5b841d2c54 | |
parent | 9c7728a137a7fb1d1ca7d4b1fdebe904fad8a471 (diff) | |
download | func-107648ae12cf37cd349f01bd7cb44b7b0584344d.tar.gz func-107648ae12cf37cd349f01bd7cb44b7b0584344d.tar.xz func-107648ae12cf37cd349f01bd7cb44b7b0584344d.zip |
export module nagios-check
-rw-r--r-- | func/minion/modules/nagios-check.py | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/func/minion/modules/nagios-check.py b/func/minion/modules/nagios-check.py index f1c0714..89f2c61 100644 --- a/func/minion/modules/nagios-check.py +++ b/func/minion/modules/nagios-check.py @@ -32,3 +32,21 @@ class Nagios(func_module.FuncModule): cmdref = sub_process.Popen(command.split(),stdout=sub_process.PIPE,stderr=sub_process.PIPE, shell=False) data = cmdref.communicate() return (cmdref.returncode, data[0], data[1]) + + def register_method_args(self): + """ + Implementing argument getter part + """ + + return{ + 'run':{ + 'args':{ + 'check_command':{ + 'type':'string', + 'optional':False, + 'description':"The command to be checked" + } + }, + 'description':"Runs a nagios check returning the return code" + } + } |