Adjust booleans in monitoring modules. (#5156) (#5170)

(cherry picked from commit 1b480e9f37)

Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
patchback[bot]
2022-08-24 20:47:17 +02:00
committed by GitHub
parent 5657889b28
commit f3a2750205
17 changed files with 50 additions and 50 deletions

View File

@@ -43,7 +43,7 @@ options:
- Create a backup file (if yes), including the timestamp information so
- you can get the original file back if you somehow clobbered it incorrectly.
type: bool
default: 'no'
default: false
command:
type: str
description:
@@ -97,7 +97,7 @@ options:
description:
- Whether the check is a metric
type: bool
default: 'no'
default: false
standalone:
description:
- Whether the check should be scheduled by the sensu client or server
@@ -153,7 +153,7 @@ EXAMPLES = '''
community.general.sensu_check:
name: cpu_load
command: /etc/sensu/plugins/system/cpu-mpstat-metrics.rb
metric: yes
metric: true
handlers: relay
subscribers: common
interval: 60
@@ -328,7 +328,7 @@ def main():
arg_spec = {'name': {'type': 'str', 'required': True},
'path': {'type': 'str', 'default': '/etc/sensu/conf.d/checks.json'},
'state': {'type': 'str', 'default': 'present', 'choices': ['present', 'absent']},
'backup': {'type': 'bool', 'default': 'no'},
'backup': {'type': 'bool', 'default': False},
'command': {'type': 'str'},
'handlers': {'type': 'list', 'elements': 'str'},
'subscribers': {'type': 'list', 'elements': 'str'},
@@ -339,7 +339,7 @@ def main():
'subdue_begin': {'type': 'str'},
'subdue_end': {'type': 'str'},
'dependencies': {'type': 'list', 'elements': 'str'},
'metric': {'type': 'bool', 'default': 'no'},
'metric': {'type': 'bool', 'default': False},
'standalone': {'type': 'bool'},
'publish': {'type': 'bool'},
'occurrences': {'type': 'int'},

View File

@@ -44,7 +44,7 @@ options:
description:
- If safe mode is enabled for the client. Safe mode requires local check definitions in order to accept a check request and execute the check.
type: bool
default: 'no'
default: false
redact:
type: list
elements: str
@@ -58,7 +58,7 @@ options:
description:
- If Sensu should monitor keepalives for this client.
type: bool
default: 'yes'
default: true
keepalive:
type: dict
description:

View File

@@ -64,12 +64,12 @@ options:
description:
- If events matching one or more silence entries should be handled.
type: bool
default: 'no'
default: false
handle_flapping:
description:
- If events in the flapping state should be handled.
type: bool
default: 'no'
default: false
command:
type: str
description:

View File

@@ -40,7 +40,7 @@ options:
- can get the original file back if you somehow clobbered it incorrectly.
type: bool
required: false
default: no
default: false
requirements: [ ]
author: Anders Ingemann (@andsens)
'''
@@ -133,7 +133,7 @@ def main():
arg_spec = {'name': {'type': 'str', 'required': True},
'path': {'type': 'str', 'default': '/etc/sensu/conf.d/subscriptions.json'},
'state': {'type': 'str', 'default': 'present', 'choices': ['present', 'absent']},
'backup': {'type': 'bool', 'default': 'no'},
'backup': {'type': 'bool', 'default': False},
}
module = AnsibleModule(argument_spec=arg_spec,