notifu 1.5.3 → 1.5.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/notifu/actors/slack.rb +2 -12
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e8704318472d7accf7172d0e3f58b35897b61052
|
4
|
+
data.tar.gz: 4c4be284cdb705f6b60f613b14c3dcfa85feec9d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 631757991b3c8662cdadaeb7df9a7408384297f04a2ef36f38b8417ca56747b80001f26f1e19a380b61ca2380032a3b11a38243374c446db192c1b3f69c40c07
|
7
|
+
data.tar.gz: 6dc1ec4e3f218a0d8dbde1164135ee7b3d86ab9b60ea98477faed2c08a08384bf53ce3df80bbeaa37c3b355d6869e339cc5a75c91321f767a49d9738eb8122e2
|
data/lib/notifu/actors/slack.rb
CHANGED
@@ -10,7 +10,7 @@ module Notifu
|
|
10
10
|
self.retry = 3
|
11
11
|
|
12
12
|
def template
|
13
|
-
|
13
|
+
"<%= data[:status] %> [<%= data[:host] %>/<%= data[:service] %>]: <%= data[:message] %> (<%= data[:duration] %>) NID:<%= data[:notifu_id] %>]"
|
14
14
|
end
|
15
15
|
|
16
16
|
def post_data
|
@@ -30,16 +30,6 @@ module Notifu
|
|
30
30
|
value: (Time.now.to_i - self.issue.time_created.to_i).duration,
|
31
31
|
short: true
|
32
32
|
},
|
33
|
-
{
|
34
|
-
title: "started",
|
35
|
-
value: Time.at(self.issue.time_created.to_i),
|
36
|
-
short: true
|
37
|
-
},
|
38
|
-
{
|
39
|
-
title: "occurrences/trigger",
|
40
|
-
value: "#{self.issue.occurrences_count}/#{self.issue.occurrences_trigger}",
|
41
|
-
short: true
|
42
|
-
},
|
43
33
|
{
|
44
34
|
title: "notifu ID",
|
45
35
|
value: self.issue.notifu_id,
|
@@ -52,7 +42,7 @@ module Notifu
|
|
52
42
|
end
|
53
43
|
|
54
44
|
def color
|
55
|
-
case self.issue.code
|
45
|
+
case self.issue.code.to_i
|
56
46
|
when 0
|
57
47
|
"good"
|
58
48
|
when 1
|