naginata 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +24 -14
- data/lib/naginata.rb +10 -10
- data/lib/naginata/version.rb +1 -1
- 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: 2561fc701669bc413ed8bbcc48f46aa054b2cd65
|
4
|
+
data.tar.gz: 8c9672f7ef3bafe0cdb60fd05f40062e19fb0565
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7c971bc2a2efa363a82696a4f7cfaae08532d22627af1007679dd41b90b9dbbd711f06f32d192b170c364261faedd1bbec6d928c6fbbc2a1fd10dd91eeb53d92
|
7
|
+
data.tar.gz: 6e51ccf9cb2e4015b3aa9e5a7ffc5ad91a23ce2377b6c7c405cb05e368392f12fe6d8d358055b81ba13e573e63637c273058cb2f210f114dba990348829c0f56
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -62,30 +62,42 @@ set :ssh_options, {
|
|
62
62
|
|
63
63
|
### Notification
|
64
64
|
|
65
|
-
#### Enable(Disable) host and service notifications
|
65
|
+
#### Enable(Disable) host and service notifications for specific host
|
66
66
|
|
67
67
|
```
|
68
68
|
$ naginata notification server001 -[e|d]
|
69
69
|
```
|
70
70
|
|
71
|
-
#### Enable(Disable) host and specific service notifications
|
71
|
+
#### Enable(Disable) host and specific service notifications for specific host
|
72
72
|
|
73
73
|
```
|
74
|
-
$ naginata notification server001 -s cpu -[e|d]
|
74
|
+
$ naginata notification server001 -s cpu -[e|d]
|
75
75
|
```
|
76
76
|
|
77
|
-
#### Enable(Disable) host and service notifications
|
77
|
+
#### Enable(Disable) host and service notifications for all hosts
|
78
78
|
|
79
79
|
```
|
80
80
|
$ naginata notification -a -[e|d]
|
81
81
|
```
|
82
82
|
|
83
|
-
####
|
83
|
+
#### With regular expression host filter
|
84
|
+
|
85
|
+
```
|
86
|
+
$ naginata notification '^web\d+.+.example.com$' -[e|d]
|
87
|
+
```
|
88
|
+
|
89
|
+
#### Enable(Disable) specific service notifications
|
84
90
|
|
85
91
|
```
|
86
92
|
$ naginata notification -a -s cpu -[e|d]
|
87
93
|
```
|
88
94
|
|
95
|
+
#### With regular expression service filters
|
96
|
+
|
97
|
+
```
|
98
|
+
$ naginata notification -a -[e|d] -s 'disk.+' -s 'https?'
|
99
|
+
```
|
100
|
+
|
89
101
|
### View service status (Experimental)
|
90
102
|
|
91
103
|
#### View service status for all hosts
|
@@ -154,29 +166,27 @@ nagios1 web01.osaka.local OK AC,NT PING OK - Packet loss = 0%, RTA = 0
|
|
154
166
|
$ naginata hosts web01.example.com db01.example.com
|
155
167
|
```
|
156
168
|
|
157
|
-
### Global Options
|
158
169
|
|
159
|
-
|
170
|
+
### Filtering by nagios servers
|
171
|
+
|
172
|
+
You can limit target nagios server with `--nagios=server1,..` option.
|
160
173
|
|
161
|
-
|
174
|
+
For example:
|
162
175
|
|
163
176
|
```
|
164
|
-
$ naginata --nagios=nagios1.example.com,nagios2.example.com
|
177
|
+
$ naginata notification -a --nagios=nagios1.example.com,nagios2.example.com -e
|
165
178
|
```
|
166
179
|
|
180
|
+
### Global Options
|
181
|
+
|
167
182
|
#### Dry run mode
|
168
183
|
|
169
184
|
naginata command with `-n` or `--dry-run` runs as dry run mode.
|
170
185
|
|
171
|
-
#### Verbose output
|
172
|
-
|
173
|
-
naginata command with `-v`
|
174
|
-
|
175
186
|
#### Debug output
|
176
187
|
|
177
188
|
naginata command with `--debug`
|
178
189
|
|
179
|
-
|
180
190
|
## Development
|
181
191
|
|
182
192
|
After checking out the repo, run `bin/setup` to install dependencies. Then, run `bin/console` for an interactive prompt that will allow you to experiment.
|
data/lib/naginata.rb
CHANGED
@@ -1,17 +1,17 @@
|
|
1
|
-
require "naginata/command/external_command"
|
2
|
-
require "naginata/configuration"
|
3
|
-
require "naginata/configuration/filter"
|
4
|
-
require "naginata/configuration/nagios_server"
|
5
|
-
require "naginata/configuration/service"
|
6
|
-
require "naginata/runner"
|
7
|
-
require "naginata/status"
|
8
|
-
require "naginata/ui"
|
9
|
-
require "naginata/version"
|
10
|
-
|
11
1
|
require "nagios_analyzer/section_decorator"
|
12
2
|
|
13
3
|
module Naginata
|
14
4
|
|
5
|
+
require "naginata/command/external_command"
|
6
|
+
require "naginata/configuration"
|
7
|
+
require "naginata/configuration/filter"
|
8
|
+
require "naginata/configuration/nagios_server"
|
9
|
+
require "naginata/configuration/service"
|
10
|
+
require "naginata/runner"
|
11
|
+
require "naginata/status"
|
12
|
+
require "naginata/ui"
|
13
|
+
require "naginata/version"
|
14
|
+
|
15
15
|
class NaginatafileNotFound < StandardError; end
|
16
16
|
|
17
17
|
class << self
|
data/lib/naginata/version.rb
CHANGED