Add Rocket.Chat notifier (#44)

This commit is contained in:
CrazyMax
2020-03-01 17:09:22 +01:00
committed by GitHub
parent 8a49f41fdd
commit 08cd3d90b8
17 changed files with 321 additions and 82 deletions

View File

@@ -52,6 +52,13 @@ func TestLoad(t *testing.T) {
Schedule: "*/30 * * * *",
},
Notif: model.Notif{
Gotify: model.NotifGotify{
Enable: false,
Endpoint: "http://gotify.foo.com",
Token: "Token123456",
Priority: 1,
Timeout: 10,
},
Mail: model.NotifMail{
Enable: false,
Host: "localhost",
@@ -59,6 +66,14 @@ func TestLoad(t *testing.T) {
SSL: false,
InsecureSkipVerify: false,
},
RocketChat: model.NotifRocketChat{
Enable: false,
Endpoint: "http://rocket.foo.com:3000",
Channel: "#general",
UserID: "abcdEFGH012345678",
Token: "Token123456",
Timeout: 10,
},
Slack: model.NotifSlack{
Enable: false,
WebhookURL: "https://hooks.slack.com/services/ABCD12EFG/HIJK34LMN/01234567890abcdefghij",
@@ -78,13 +93,6 @@ func TestLoad(t *testing.T) {
},
Timeout: 10,
},
Gotify: model.NotifGotify{
Enable: false,
Endpoint: "http://gotify.foo.com",
Token: "Token123456",
Priority: 1,
Timeout: 10,
},
},
RegOpts: map[string]model.RegOpts{
"someregopts": {