canaryBot/README.md
README.mdRaw
1# canaryBot
2Bot to check if services are alive.
3Current bots:
4- Matrix (Riot)
5
6
7#### Config
8File `config.json`
9```json
10{
11 "matrix": {
12 "room_id": "!zzzzz:mmmmmm.ooo",
13 "user": "aaaaa",
14 "password": "xxxxx",
15 "server": "https://sssss.ooo"
16 },
17 "services": [{
18 "name": "name01",
19 "url": "http://127.0.0.1:80",
20 "statusCode": 200
21 },
22 {
23 "name": "service02",
24 "url": "http://127.0.0.1:7000/api",
25 "statusCode": 200
26 }
27 ],
28 "sleepTime": 30,
29 "retry": 5
30}
31```
32
33- sleepTime: time between each request to the services
34- retry: after X times failing, restart the counter
35
36### Run
37```
38./canaryBot
39```