Add files via upload

caching issue fixed
This commit is contained in:
Chriz 2023-05-25 20:05:23 +02:00 committed by GitHub
parent 039d483077
commit 2e8ed699bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,7 +27,7 @@
## * smartdisk - install the mkp from https://github.com/bashclub/checkmk-smart plugins os-smart ## * smartdisk - install the mkp from https://github.com/bashclub/checkmk-smart plugins os-smart
## * squid - install the mkp from https://exchange.checkmk.com/p/squid and forwarder -> listen on loopback active ## * squid - install the mkp from https://exchange.checkmk.com/p/squid and forwarder -> listen on loopback active
__VERSION__ = "1.0.3" __VERSION__ = "1.0.4"
import sys import sys
import os import os
@ -217,7 +217,10 @@ class checkmk_checker(object):
except: except:
_cachetime = 0 _cachetime = 0
try: try:
_lines.append(self._run_cache_prog(_plugin_file,_cachetime)) if _cachetime > 0:
_lines.append(self._run_cache_prog(_plugin_file,_cachetime))
else:
_lines.append(self._run_prog(_plugin_file))
except: except:
_errors.append(traceback.format_exc()) _errors.append(traceback.format_exc())
@ -241,7 +244,10 @@ class checkmk_checker(object):
except: except:
_cachetime = 0 _cachetime = 0
try: try:
_lines.append(self._run_cache_prog(_local_file,_cachetime)) if _cachetime > 0:
_lines.append(self._run_cache_prog(_local_file,_cachetime))
else:
_lines.append(self._run_prog(_local_file))
except: except:
_errors.append(traceback.format_exc()) _errors.append(traceback.format_exc())