148 Commits

Author SHA1 Message Date
Spencer Sun
ae30eec1d0 Add GET /api/v1/checks/ to the API 2016-04-05 11:58:00 -07:00
Pēteris Caune
da613963e9 Email alerts and monthly reports have links to Log pages.
Don't show ping URLs -- gmail converts them to clickable links, and people click on them.
2016-03-08 10:35:39 +02:00
Pēteris Caune
6efb822f95 When creating a check via API, optionally assign all channels. 2016-02-17 22:35:06 +02:00
Pēteris Caune
5725a3a30a Use six.string_types. This hopefully fixes python 2 test failures. 2016-02-16 23:50:41 +02:00
Pēteris Caune
5d2edfa4a0 First stab at API, POST /api/v1/checks 2016-02-16 23:41:40 +02:00
Pēteris Caune
5d2cc0b0fc Set and revoke API key in Settings page. 2016-02-16 15:08:13 +02:00
Pēteris Caune
6bb08e16d6 Updated instructions and JSON payload for VictorOps integration. 2016-02-04 09:21:58 +02:00
Spencer Sun
0ff2f1a9c7 Add VictorOps integration 2016-02-03 17:35:29 -05:00
Pēteris Caune
dce16e6249 Less code duplication in hc.api.transports 2016-01-31 21:59:08 +02:00
Pēteris Caune
24c111738a Pushover API expects form-data instead of JSON 2016-01-31 20:57:39 +02:00
Pēteris Caune
a71ce64579 Fix Pushover and HipChat. 2016-01-31 20:41:04 +02:00
Pēteris Caune
2c04a42a57 Display last notification in Integrations page. 2016-01-31 20:29:49 +02:00
Pēteris Caune
c7a651c330 sendalerts management command prints error messages to stdout. 2016-01-31 19:48:21 +02:00
Pēteris Caune
156f4dbeea More tests for notifications. 2016-01-31 19:30:02 +02:00
Pēteris Caune
90d7806783 More tests for notifications. 2016-01-31 18:54:35 +02:00
Pēteris Caune
21a042aa16 Move notification logic to hc.api.transports. Don't use "paused" state for checks. 2016-01-31 18:35:24 +02:00
Pēteris Caune
63cc186fa3 Nicer slack messages. 2016-01-23 15:18:59 +02:00
Pēteris Caune
e67d0f58c0 Merge pull request #33 from BetterWorks/betterIPParsing
Use X-Forwarded-For and X-Forwarded-Proto headers, instead of X-Real-IP and X-Scheme
2016-01-22 11:44:25 +02:00
Love Sharma
25b3af6e40 Merge pull request #1 from zonito/master
test fix
2016-01-22 14:17:02 +08:00
Love Sharma
ddfcb0ff2a test fix 2016-01-22 14:16:16 +08:00
Love Sharma
35e9c17f74 Add healthcheck UA to inform server about identity
Adding "healthcheck.io" as User-Agent to inform webhook handler server about request is specific from healthcheck.
2016-01-22 13:57:20 +08:00
Di Wu
2e6df69489 forwarded for and forwarded protocol 2016-01-21 18:36:26 -08:00
Di Wu
fe72792fd2 use basetestcase for most test cases that require predefined user, add test for ensuretriggers, add travis cache 2016-01-18 01:02:42 -08:00
Pēteris Caune
68fe11a41b fillnpings catches up with pings received during the execution of the command 2016-01-08 14:16:50 +02:00
Pēteris Caune
b592e5b449 prunepingsslow command skips checks with user_id=null 2016-01-08 12:48:36 +02:00
Di Wu
79b7327c9e fix tests and optimize authentication and fix some unclosed markup 2016-01-04 23:47:32 -05:00
Pēteris Caune
1e3285423f Ping objects get "n" field, their serial numbers, used in "log page". "fillnpings" management command initially populates this field (it touches every ping so it takes time to complete).
Check.n_pings now stores the total number of pings the check has ever received. Running "prunepings" command doesn't affect this field. +a new "prunepingsslow" command which works in smaller chunks so is appropriate for initial pruning of a huge api_ping table.
2016-01-03 18:11:12 +02:00
Pēteris Caune
4e12193d8c Custom test runner for quicker tests. 2016-01-02 23:04:03 +02:00
Pēteris Caune
b9ae8d464c Sort by id, not created, when pruning pings. 2016-01-02 22:27:25 +02:00
Pēteris Caune
7019325b48 Investigating Travis/mysql test failure 2016-01-02 22:13:48 +02:00
Pēteris Caune
940534e563 Test for check.prune_pings() method 2016-01-02 21:54:04 +02:00
Pēteris Caune
5a199fec4e management commands use self.stdout.write instead of print. Fixes #21 2015-12-30 21:56:03 +02:00
Pēteris Caune
b7fcaac8ae prunepings and prunechecks management commands 2015-12-30 21:11:00 +02:00
Pēteris Caune
15478d414c Add n_pings field to Check model. This holds a continually updated count of api_ping entries for each check. 2015-12-30 14:30:38 +02:00
Pēteris Caune
1c2ee95968 Django 1.9 2015-12-30 14:01:19 +02:00
Pēteris Caune
4da8ebec88 Management command to send monthly reports. 2015-12-18 03:53:00 +02:00
Pēteris Caune
35aed93b7f New feature: attaching tags to checks, and filtering checks list by their tags. 2015-12-14 12:52:42 +02:00
Pēteris Caune
d51d7ed181 Remove body field from Ping model. 2015-12-12 17:03:34 +02:00
Pēteris Caune
33ad56728c Don't fill in body, will be removing it from model. 2015-12-12 16:59:58 +02:00
Pēteris Caune
3ba47b1a67 Style tweaks for PushOver integration 2015-12-02 14:46:41 +02:00
Thomas Jost
280bd6a2a2 Handle Pushover emergency notifications 2015-11-25 16:58:52 +01:00
Thomas Jost
85c1f65887 Add Pushover integration 2015-11-25 16:06:24 +01:00
Pēteris Caune
c2e9bab536 Custom paginator to avoid sequential scans on api_ping table in Django admin. 2015-11-11 09:28:29 +02:00
Pēteris Caune
89f0c6bd77 Avoid sequential scans on api_ping table in Django admin. 2015-11-10 20:15:26 +02:00
Pēteris Caune
947f686c61 Organize imports using isort. 2015-11-02 23:55:33 +02:00
Pēteris Caune
0512e8a7c5 Testcase for handle_many function in sendalerts management command. 2015-11-02 23:51:35 +02:00
Di Wu
93c71ad10e timeout on all the notifications 2015-10-30 23:47:07 -07:00
Di Wu
de203275c6 sendalerts concurrently 2015-10-30 23:44:08 -07:00
Pēteris Caune
c1840a92bd Checks now have a new status: "paused". sendalerts management command will mark checks as paused if sending a notification throws exception. This should avoid potential infinite loops of sendalerts crashes/respawns. 2015-10-30 14:21:12 +02:00
Pēteris Caune
b19477106e Avoid N queries in Pings admin list view 2015-10-28 09:59:16 +02:00