Commit graph

329 commits

Author SHA1 Message Date
Mstislav Bobakov
6ef3697c52 Add custom parameter for a sensu_check. Fixes.
JSON replaced within dict.
Added more docs.
2016-01-28 15:42:09 +03:00
Ryan G. Hunter
a59aa2cb34 monit startup fix 2016-01-21 10:56:58 -05:00
Mstislav Bobakov
8e35db0e38 Add custom parameter for a sensu_check 2016-01-21 13:08:25 +03:00
Brian Coca
3aa2d3744d Merge pull request #1482 from ansible/json-imports-fallback
Update for modules which import json.
2016-01-12 10:00:37 -05:00
Brian Coca
520d245ae7 added note on choice version availability 2016-01-11 19:06:44 -05:00
Brian Coca
4ca07d511e Merge pull request #1248 from hypergig/devel
support for event alert monitors
2016-01-11 19:01:36 -05:00
Toshio Kuratomi
d6af6f8477 Update for modules which import json.
Some do not use the json module directly so don't need import json.
Some needed to fallback to simplejson with no traceback if neither was installed

Fixes #1298
2016-01-11 13:06:22 -08:00
Michael Scherer
2f3dc1352f Replace choices=BOOLEANS by type='bool', fix #1326 2015-12-21 23:39:20 +01:00
Brian Coca
a6ceec998d corrected version_added for new monit timeout opt 2015-12-14 21:47:26 -05:00
Brian Coca
91df684902 Merge pull request #806 from gaqzi/monit/retry-option
monit: Add retry for pending/initializing services
2015-12-14 21:42:56 -05:00
Bruce Pennypacker
5abd7deab0 Remove extraneous space from end of command string in nagios_cmd 2015-12-11 16:06:33 +00:00
Michael Weber
fba8c9f8a7 Fix error 'fail_json() takes exactly 1 argument'
Fixes bug #1257
2015-12-01 01:56:23 -08:00
Björn Andersson
72155d40a3 monit: Set a high timeout waiting for status changes
Instead of waiting for up to a certain number of retries we set a high
timeout and only re-check every five seconds. Certain services can
take a minute or more to start and we want to avoid waisting resources
by polling too often.
2015-11-29 23:44:58 +08:00
Björn Andersson
262f2e9048 monit: Add version_added and type for new argument 2015-11-29 22:21:38 +08:00
Björn Andersson
5835d06a4e monit: Wait for pending state changes for reloads
@mpeters reported that we're not checking that the named service is
actually there after a reload. And that sometimes monit doesn't actually
return anything at all after a reload.
2015-11-29 22:21:38 +08:00
Björn Andersson + SU Sheng Loong
f8fe5a2fcd monit: Add retry for pending/initializing services
If there are already ongoing actions for a process managed by monit, the
module would exit unsuccessfully. It could also give off false positives
because it did not determine whether the service was started/stopped
when it was in a pending state. Which might be turning the service off,
but the action was to start it.

For example "Running - pending stop" would be regarded as the service
running and "state=enabled" would do nothing.

This will make Ansible wait for the state to finalize, or a timeout decided
by the new `max_retries` option, before it decides what to do.

This fixes issue #244.
2015-11-29 22:21:38 +08:00
Jordan Cohen
20d6e3daaf support for event alert monitors 2015-11-16 06:31:14 -05:00
Brian Coca
875a055103 corrected choices which was meant to be type 2015-11-15 14:31:34 -08:00
Ritesh Khadgaray
5e103d604a allows user to not update zabbix host config if host is present. 2015-11-09 20:21:28 +05:30
Kerim Satirli
2ac53bf559 fixes a typo in Datadog Monitor docs 2015-11-06 11:02:51 +01:00
Konstantin Manna
97b7a7a7f8 bugfix: use correct function close calls 2015-09-30 10:13:12 -04:00
Brian Coca
6cd7399a71 minor docfix 2015-09-22 21:02:49 -04:00
Brian Coca
076ddc5266 Merge pull request #1002 from knakayama/bugfix/fix-argument-type-for-zabbix_screen
Fix argument type for zabbix_screen
2015-09-22 21:00:07 -04:00
Brian Coca
c7c32ef86f minor doc fixes nagios 2015-09-22 13:58:36 -04:00
Brian Coca
5017c4483a Merge pull request #798 from vaupelt/patch-1
strange results with services=all

agreed, the doc issues are unrelated to this PR, will fix those independently
2015-09-22 13:49:46 -04:00
knakayama
45f4568753 Fix argument type for zabbix_screen 2015-09-20 18:18:58 +09:00
Anders Ingemann
e0f513a903 Fix state & metric description
Also: add state=absent to last example
2015-09-17 12:12:54 +02:00
Anders Ingemann
9342c16e78 Add github ID to author field in sensu_check
As proposed by @gregdek in #983
2015-09-17 12:04:04 +02:00
Darren Worrall
b0926125c2 Fix json loading in sensu_check
Fixes `AttributeError: 'str' object has no attribute 'read'` when the
check path exists
2015-09-15 16:43:26 +01:00
Darren Worrall
4ead053031 Initialise stream variable
Fixes `UnboundLocalError: local variable 'stream' referenced before
assignment` when the check path doesnt exist
2015-09-15 16:40:01 +01:00
Tim Bielawa
c9785a6948 Fix capitalization in nagios 'services' parameter comment 2015-08-31 13:14:05 -04:00
Amanpreet Singh
a0af060c25 Make pagerduty_alert module more inline with ansible modules
- use state parameter instead of event_type
- add support for check mode
2015-08-27 18:05:46 +05:30
Amanpreet Singh
0847bfecd6 Add new module: pagerduty_alert
- trigger, acknowledge or resolve pagerduty incidents
2015-08-27 18:00:17 +05:30
vaupelt
150d3ce0ee strange results with services=all
I issued a command with action=disable_alerts host=webserver services=all set and get this results:

    "nagios_commands": [
        "[1438593631] DISABLE_SVC_NOTIFICATIONS;webserver;a", 
        "[1438593631] DISABLE_SVC_NOTIFICATIONS;webserver;l", 
        "[1438593631] DISABLE_SVC_NOTIFICATIONS;webserver;l"
    ]

This is not a big deal because i have just overlooked the action=silence command. Nevertheless a more predictable result would be a nice thing to have.
2015-08-03 12:38:16 +02:00
Brian Coca
27bf193483 added missing license headers
fixes #508
2015-07-30 14:48:59 -04:00
Toshio Kuratomi
aa1b4caa8a Merge pull request #734 from ansible/fetch_url-uptimerobot
Port uptimerobot to fetch_url
2015-07-28 11:21:08 -07:00
Toshio Kuratomi
4a43f52437 Use fetch_url's basic auth instead of code specific to this module 2015-07-28 10:51:13 -07:00
Toshio Kuratomi
8aa490c638 Port uptimerobot to fetch_url 2015-07-20 23:22:33 -07:00
Toshio Kuratomi
626977f90e Port librarto_annotation from urllib2 to fetch_url 2015-07-20 23:09:59 -07:00
Toshio Kuratomi
79173ac18d Clean up unneeded urllib2 imports 2015-07-20 23:04:27 -07:00
Greg DeKoenigsberg
d640fd95e9 Merge pull request #605 from bpennypacker/pagerduty_updates
monitoring/pagerduty module improvements, including specifying multiple services, fixing task output, adding 'delete'' action
2015-07-04 15:40:23 -04:00
Eike Frost
75e1e9fcda add zabbix proxy support to zabbix_host 2015-06-21 21:59:36 +02:00
Brian Coca
3f9e2fb4e6 Merge pull request #629 from bcoca/sensu_check_2.4
made sensu_check 2.4 friendly
2015-06-19 12:22:59 -04:00
Brian Coca
286bc3d9dc forgot finally 2.4 syntax 2015-06-19 12:13:43 -04:00
Brian Coca
eeb9d34812 also fixed exceptions 2015-06-19 12:10:14 -04:00
Toshio Kuratomi
dd6e8f354a Modify a few more modules to not conditionalize urllib(2) import. 2015-06-19 09:07:04 -07:00
Brian Coca
1659af1541 made sensu_check 2.4 friendly 2015-06-19 12:05:50 -04:00
Toshio Kuratomi
4b29146c4d be explicit about urllib import and remove conditional urllib(2) import
urllib and urllib2 have been in the python stdlib since at least
python-2.3.  There's no reason to conditionalize it.

Fixes https://github.com/ansible/ansible/issues/11322
2015-06-19 09:01:08 -07:00
Brian Coca
8f31d84300 Merge pull request #203 from andsens/sensu-check
Add sensu_check module
2015-06-19 11:17:42 -04:00
Anders Ingemann
3f3a73da37 Add sensu_check module 2015-06-19 09:58:14 +02:00
Greg DeKoenigsberg
004dedba8a Changes to author formatting, remove emails 2015-06-16 14:32:39 -04:00
Brian Coca
0d7332d550 minor docfix 2015-06-16 11:33:16 -04:00
Greg DeKoenigsberg
98abb6d2c9 Adding author's github id 2015-06-16 11:33:16 -04:00
Jhonny Everson
4b625bab34 Fixes the bug where it was using only the keys to determine whether a change was made, i.e. values changes for existing keys was reported incorrectly. 2015-06-16 11:33:16 -04:00
Jhonny Everson
d722d6de97 Adds handler for error responses 2015-06-16 11:33:15 -04:00
Sebastian Kornehl
fdaa4da447 docs: removed default when required is true 2015-06-16 11:33:14 -04:00
Sebastian Kornehl
1291f9a25a Added datadog_monitor module 2015-06-16 11:33:14 -04:00
Brian Coca
6050cc8e5d push list nature of tags into spec to allow both for comma delimited strings and actual lists 2015-06-16 11:33:14 -04:00
Brian Coca
d5c581e9eb updated docs for 2.0 2015-06-16 11:33:13 -04:00
Brian Coca
04e43a9dcb added version added 2015-06-16 11:33:13 -04:00
Greg DeKoenigsberg
432477c14c Revert "Added eval for pasting tag lists" 2015-06-16 11:33:13 -04:00
Sebastian Kornehl
5b7b74eb66 Added eval for pasting tag lists 2015-06-16 11:33:11 -04:00
Lorenzo Luconi Trombacchi
51b11fd1af status function was called twice 2015-06-16 11:33:10 -04:00
Lorenzo Luconi Trombacchi
16db10958b fix a problem with status detection after unmonitor command 2015-06-16 11:33:10 -04:00
Lorenzo Luconi Trombacchi
2bcb0d4c08 added lower function for statuses 2015-06-16 11:33:10 -04:00
Todd Zullinger
d604f56162 monitoring/nagios: Allow comment to be specified
The default remains 'Scheduling downtime' but can be overridden.
2015-06-16 11:33:09 -04:00
Kevin Klinemeier
49ab501be4 Updated tags example to an actual datadog tag 2015-06-16 11:33:09 -04:00
Michael Gröning
f9041a1b29 fix bugs 2015-06-16 11:33:08 -04:00
Michael Gröning
304abbce85 improved docs 2015-06-16 11:33:08 -04:00
Michael Gröning
0b9863ed0e divided between host an service downtimes 2015-06-16 11:33:08 -04:00
Michael Gröning
8829b818b8 add function for servicegrup downtimes 2015-06-16 11:33:08 -04:00
Bruce Pennypacker
9285d0a1c7 changed 'deleted' to 'absent' 2015-06-14 20:20:36 +00:00
Bruce Pennypacker
51bba578b6 Updated 'ongoing' to also return properly formatted json 2015-06-12 19:58:57 +00:00
Bruce Pennypacker
6a89b92cda Fixed results & 'Changed'. Added 'deleted' action. Added ability to specify multiple services. 2015-06-12 18:36:23 +00:00
Brian Coca
2f967a949f minor docfix 2015-06-10 12:58:59 -04:00
Greg DeKoenigsberg
ef7381f246 Adding author's github id 2015-06-09 12:58:45 -04:00
Jhonny Everson
d517abf44b Fixes the bug where it was using only the keys to determine whether a change was made, i.e. values changes for existing keys was reported incorrectly. 2015-06-09 09:44:34 -03:00
Jhonny Everson
f09389b179 Adds handler for error responses 2015-06-08 17:46:53 -03:00
Brian Coca
06c60ddc22 Merge pull request #575 from skornehl/devel
datadog_monitor module
2015-06-05 21:47:15 -04:00
Sebastian Kornehl
df618c2d48 docs: removed default when required is true 2015-06-04 06:54:02 +02:00
Brian Coca
e03ed0bd34 Merge pull request #481 from LorenzoLuconi/devel
2 bug fixes for monit module
2015-06-03 08:48:47 -04:00
Sebastian Kornehl
9ee29fa579 Added datadog_monitor module 2015-06-03 13:15:59 +02:00
Greg DeKoenigsberg
d6dccfb269 Merge pull request #317 from agilekevin/patch-1
Updated tags example to an actual datadog tag
2015-06-02 13:52:19 -04:00
Brian Coca
5da651212f push list nature of tags into spec to allow both for comma delimited strings and actual lists 2015-06-02 08:37:45 -04:00
Brian Coca
3861904b02 updated docs for 2.0 2015-06-01 12:36:49 -04:00
Brian Coca
35a86c3423 Merge pull request #228 from michaelgroening/devel
enable setting downtimes for Service-Group services and hosts
2015-06-01 12:31:41 -04:00
Brian Coca
4b35db4932 added version added 2015-06-01 12:31:34 -04:00
Brian Coca
27bb709a73 Merge pull request #324 from tmzullinger/nagios-comment-support
monitoring/nagios: Allow comment to be specified
2015-06-01 12:26:50 -04:00
Greg DeKoenigsberg
223694ccf2 Revert "Added eval for pasting tag lists" 2015-06-01 12:07:23 -04:00
Greg DeKoenigsberg
9f9b50996e Merge pull request #512 from skornehl/devel
Added eval for pasting tag lists
2015-06-01 09:17:20 -04:00
Toshio Kuratomi
1276420a3a Fix documentation formatting 2015-05-28 16:00:43 -07:00
Brian Coca
0ff9bced72 Merge pull request #524 from resmo/feature/zabbix_group2
replace module zabbix_group
2015-05-28 08:02:26 -04:00
Toshio Kuratomi
8b62a45466 Fix docs - don't need quote anymore 2015-05-26 15:40:20 -07:00
Rene Moser
d04e6b1d07 zabbix_maintenance: prevent to log password 2015-05-26 15:41:37 +02:00
Rene Moser
1eb6c37594 zabbix: improve module doc 2015-05-26 15:34:35 +02:00
Rene Moser
9d07fb9618 zabbix: improve arguments and prevent to log password 2015-05-26 15:33:50 +02:00
Rene Moser
c9dfeb07c1 zabbix: remove redundant import of module_utils 2015-05-26 15:28:50 +02:00
Rene Moser
c0fb48cd39 zabbix_group: improve params 2015-05-22 15:25:13 +02:00
Rene Moser
3f108732c5 zabbix_group: add backword compatibility
* add alias host_group for host_groups
* add choices for param state
2015-05-22 15:25:13 +02:00
Rene Moser
1c210abc69 zabbix_group: update version added to 1.8
Since we intent to replace the current module, we add the version the current module was added.
2015-05-22 15:25:12 +02:00