diff options
author | Adrian Likins <alikins@grimlock.devel.redhat.com> | 2008-08-26 14:51:26 -0400 |
---|---|---|
committer | Adrian Likins <alikins@grimlock.devel.redhat.com> | 2008-08-26 14:51:26 -0400 |
commit | 31f096ef3065c13945c96b815ff4feeaf1a46e11 (patch) | |
tree | 399ad8a88ecba9611f5b38b5982c3520c777139e /func/minion/modules/nagios-check.py | |
parent | 44733335dd76b59e211e8397f008abdba79a3b5f (diff) | |
parent | 41f53ee4a0edb6899b8377dabbdba525cb6d1844 (diff) | |
download | func-31f096ef3065c13945c96b815ff4feeaf1a46e11.tar.gz func-31f096ef3065c13945c96b815ff4feeaf1a46e11.tar.xz func-31f096ef3065c13945c96b815ff4feeaf1a46e11.zip |
Merge branch 'master' into cmd_run_env
Diffstat (limited to 'func/minion/modules/nagios-check.py')
-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" + } + } |