1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Add include_tags to datadog_monitor (#409)

* Add include_tags to datadog_monitor

* Incorporate PR feedback

* Add changelog fragment

* Update changelogs/fragments/409-datadog-monitor-include-tags.yaml

Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>

* Update plugins/modules/monitoring/datadog/datadog_monitor.py

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>
Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
Ty Martin 2020-10-23 00:12:22 -05:00 committed by GitHub
parent 7caba156fa
commit 307c54750f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 2 deletions

View file

@ -0,0 +1,2 @@
minor_changes:
- datadog_monitor - add ``include_tags`` option (https://github.com/ansible/ansible/issues/57441).

View file

@ -135,6 +135,12 @@ options:
- The ID of the alert.
- If set, will be used instead of the name to locate the alert.
type: str
include_tags:
description:
- Whether notifications from this monitor automatically inserts its triggering tags into the title.
type: bool
default: yes
version_added: 1.3.0
'''
EXAMPLES = '''
@ -219,7 +225,8 @@ def main():
require_full_window=dict(required=False, default=None, type='bool'),
new_host_delay=dict(required=False, default=None),
evaluation_delay=dict(required=False, default=None),
id=dict(required=False)
id=dict(required=False),
include_tags=dict(required=False, default=True, type='bool'),
)
)
@ -333,7 +340,8 @@ def install_monitor(module):
"locked": module.boolean(module.params['locked']),
"require_full_window": module.params['require_full_window'],
"new_host_delay": module.params['new_host_delay'],
"evaluation_delay": module.params['evaluation_delay']
"evaluation_delay": module.params['evaluation_delay'],
"include_tags": module.params['include_tags'],
}
if module.params['type'] == "service check":