malsh 0.3.1 → 0.3.2
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/malsh/notification/base.rb +4 -2
- data/lib/malsh/notification/slack.rb +1 -1
- data/lib/malsh/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f7f1081b9a67afe8ff4e228f5070dcf491a507b2165ac51490a17817640a1712
|
4
|
+
data.tar.gz: 6bb4a33106d0c9847b2d2073dfe2e30c2b65542885e9c30a133ebba78581635b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 135c8b2509f0fb9b3738469cb7f5bb19d357faa71b7b1f5c36c27a2202872f58d824f68303bb846f7dcd5bcdbf9133fc7fea876cfa3463294676144de7d934f6
|
7
|
+
data.tar.gz: c32b5fe8280c1bd682cb361bf61eee792bb865ea9e3eb44ed34bd00b8d143370522761a8df93ac9cb01cbe5b887b0444edd74e08be8c555be965d2ff94bd26db
|
@@ -1,8 +1,10 @@
|
|
1
1
|
module Malsh::Notification
|
2
2
|
class Base
|
3
3
|
def self.notify_host(subject, hosts)
|
4
|
-
|
5
|
-
|
4
|
+
puts "#{subject}:"
|
5
|
+
hosts.map do |h|
|
6
|
+
puts "#{h.name}(#{h.roles.keys.join(",")})"
|
7
|
+
end if doit?
|
6
8
|
end
|
7
9
|
|
8
10
|
def self.notify_alert(subject, alerts)
|
@@ -5,7 +5,7 @@ module Malsh::Notification
|
|
5
5
|
return unless doit?
|
6
6
|
lists = if Malsh.options[:org]
|
7
7
|
hosts.map do |h|
|
8
|
-
"<https://mackerel.io/orgs/#{Malsh.options[:org]}/hosts/#{h.id}/-/setting|#{h.name}>"
|
8
|
+
"<https://mackerel.io/orgs/#{Malsh.options[:org]}/hosts/#{h.id}/-/setting|#{h.name}(#{h.roles.keys.join(",")})>"
|
9
9
|
end
|
10
10
|
else
|
11
11
|
hosts.map(&:name)
|
data/lib/malsh/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: malsh
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- kazuhiko yamahsita
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-07-
|
11
|
+
date: 2020-07-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|