mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-21 18:41:03 +00:00
Change if conditions to please the linter.
This commit is contained in:
parent
76c21fe7ef
commit
409e88968d
2 changed files with 8 additions and 8 deletions
|
@ -106,7 +106,7 @@ def munin_config(fs):
|
|||
print("corruption_errs.label Corruption Errors")
|
||||
print("corruption_errs.warning " + os.getenv('corruption_errs_warning',
|
||||
default = str(warning)))
|
||||
if os.getenv('corruption_errs_critical', default = critical) != False:
|
||||
if os.getenv('corruption_errs_critical', default = critical):
|
||||
print("corruption_errs.critical " +
|
||||
os.getenv('corruption_errs_critical',
|
||||
default = str(critical)))
|
||||
|
@ -114,14 +114,14 @@ def munin_config(fs):
|
|||
print("flush_errs.label Flush Errors")
|
||||
print("flush_errs.warning " + os.getenv('flush_errs_warning',
|
||||
default = str(warning)))
|
||||
if os.getenv('flush_errs_critical', default = critical) != False:
|
||||
if os.getenv('flush_errs_critical', default = critical):
|
||||
print("flush_errs.critical " + os.getenv('flush_errs_critical',
|
||||
default = str(critical)))
|
||||
|
||||
print("generation_errs.label Generation Errors")
|
||||
print("generation_errs.warning " + os.getenv('generation_errs_warning',
|
||||
default = str(warning)))
|
||||
if os.getenv('generation_errs_critical', default = critical) != False:
|
||||
if os.getenv('generation_errs_critical', default = critical):
|
||||
print("generation_errs.critical " +
|
||||
os.getenv('generation_errs_critical',
|
||||
default = str(critical)))
|
||||
|
@ -129,14 +129,14 @@ def munin_config(fs):
|
|||
print("read_errs.label Read Errors")
|
||||
print("read_errs.warning " + os.getenv('read_errs_warning',
|
||||
default = str(warning)))
|
||||
if os.getenv('read_errs_critical', default = critical) != False:
|
||||
if os.getenv('read_errs_critical', default = critical):
|
||||
print("read_errs.critical " + os.getenv('read_errs_critical',
|
||||
default = str(critical)))
|
||||
|
||||
print("write_errs.label Write Errors")
|
||||
print("write_errs.warning " + os.getenv('write_errs_warning',
|
||||
default = str(warning)))
|
||||
if os.getenv('write_errs_critical', default = critical) != False:
|
||||
if os.getenv('write_errs_critical', default = critical):
|
||||
print("write_errs.critical " + os.getenv('write_errs_critical',
|
||||
default = str(critical)))
|
||||
|
||||
|
@ -145,7 +145,7 @@ def munin_config(fs):
|
|||
print("flags.label Nr. of Flags")
|
||||
print("flags.warning " + os.getenv('flags_warning',
|
||||
default = str(warning)))
|
||||
if os.getenv('flags_critical', default = critical) != False:
|
||||
if os.getenv('flags_critical', default = critical):
|
||||
print("flags.critical " + os.getenv('flags_critical',
|
||||
default = str(critical)))
|
||||
|
||||
|
|
|
@ -103,10 +103,10 @@ def munin_config(fs):
|
|||
this_dev_name = this_dev_info.path.replace('/dev/', '')
|
||||
print("btrfs_bytes_" + fsid + "_" + str(this_device.devid) +
|
||||
".label " + this_dev_name)
|
||||
if byte_warning != False:
|
||||
if byte_warning:
|
||||
print("btrfs_bytes_" + fsid + "_" + str(this_device.devid) +
|
||||
".warning " + str(byte_warning))
|
||||
if byte_critical != False:
|
||||
if byte_critical:
|
||||
print("btrfs_bytes_" + fsid + "_" + str(this_device.devid) +
|
||||
".critical " + str(byte_critical))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue