sensu-plugins-jenkins 1.4.0 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +6 -1
- data/bin/check-jenkins-health.rb +17 -1
- data/lib/sensu-plugins-jenkins/version.rb +1 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 34bf4bc9191288a0e8ed07eb0d39fab42fc4d631
|
4
|
+
data.tar.gz: 4c8d3f81b7d26dcef616388f4e2d56f9791a882d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b3144cec8d2e81bf6aa79c2406e8a61b5ab3b407c96b7280ab1167b18fed45748190aec2884250bec2cfd1967abf4f23ae5e27672d4c6f2d381a39b63b32f61
|
7
|
+
data.tar.gz: 4d4f02dffbaeb3dee37a32b003d1c01ccdee0ac3bad5a9c2ae3ff035792bf098a7ddc732b0e1609873092731101f75bd47ce866e4a0f0477eb7f719bc3b065f5
|
data/CHANGELOG.md
CHANGED
@@ -6,6 +6,10 @@ Which is based on [Keep A Changelog](http://keepachangelog.com/)
|
|
6
6
|
|
7
7
|
## [Unreleased]
|
8
8
|
|
9
|
+
## [1.5.0] - 2018-02-17
|
10
|
+
### Added
|
11
|
+
- check-jenkins-health.rb: Add --insecure parameter to allow self signed ssl certs (@sabbene)
|
12
|
+
|
9
13
|
## [1.4.0] - 2017-11-15
|
10
14
|
### Added
|
11
15
|
- Add Ruby 2.4.1 testing
|
@@ -73,7 +77,8 @@ Which is based on [Keep A Changelog](http://keepachangelog.com/)
|
|
73
77
|
### Added
|
74
78
|
- initial release
|
75
79
|
|
76
|
-
[Unreleased]: https://github.com/sensu-plugins/sensu-plugins-jenkins/compare/1.
|
80
|
+
[Unreleased]: https://github.com/sensu-plugins/sensu-plugins-jenkins/compare/1.5.0...HEAD
|
81
|
+
[1.5.0]: https://github.com/sensu-plugins/sensu-plugins-jenkins/compare/1.4.0...1.5.0
|
77
82
|
[1.4.0]: https://github.com/sensu-plugins/sensu-plugins-jenkins/compare/1.3.0...1.4.0
|
78
83
|
[1.3.0]: https://github.com/sensu-plugins/sensu-plugins-jenkins/compare/1.2.0...1.3.0
|
79
84
|
[1.2.0]: https://github.com/sensu-plugins/sensu-plugins-jenkins/compare/1.1.0...1.2.0
|
data/bin/check-jenkins-health.rb
CHANGED
@@ -61,6 +61,13 @@ class JenkinsMetricsHealthChecker < Sensu::Plugin::Check::CLI
|
|
61
61
|
description: 'Enabling https connections',
|
62
62
|
default: false
|
63
63
|
|
64
|
+
option :insecure,
|
65
|
+
short: '-k',
|
66
|
+
long: '--insecure',
|
67
|
+
boolean: true,
|
68
|
+
description: 'Perform "insecure" SSL connections and transfers.',
|
69
|
+
default: false
|
70
|
+
|
64
71
|
option :timeout,
|
65
72
|
short: '-t SECS',
|
66
73
|
long: '--timeout SECS',
|
@@ -70,7 +77,16 @@ class JenkinsMetricsHealthChecker < Sensu::Plugin::Check::CLI
|
|
70
77
|
|
71
78
|
def run
|
72
79
|
https ||= config[:https] ? 'https' : 'http'
|
73
|
-
|
80
|
+
testurl = "#{https}://#{config[:server]}:#{config[:port]}#{config[:uri]}"
|
81
|
+
|
82
|
+
r = if config[:https] && config[:insecure]
|
83
|
+
RestClient::Resource.new(testurl, timeout: config[:timeout], verify_ssl: false).get
|
84
|
+
elsif config[:https]
|
85
|
+
RestClient::Resource.new(testurl, timeout: config[:timeout], verify_ssl: true).get
|
86
|
+
else
|
87
|
+
RestClient::Resource.new(testurl, timeout: config[:timeout]).get
|
88
|
+
end
|
89
|
+
|
74
90
|
if [200, 500].include? r.code
|
75
91
|
healthchecks = JSON.parse(r)
|
76
92
|
healthchecks.each do |healthcheck, healthcheck_hash_value|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sensu-plugins-jenkins
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sensu-Plugins and contributors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-02-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sensu-plugin
|
@@ -218,12 +218,12 @@ description: |-
|
|
218
218
|
health, job status, metrics via `JQS`, and others
|
219
219
|
email: "<sensu-users@googlegroups.com>"
|
220
220
|
executables:
|
221
|
-
- check-jenkins-build-time.rb
|
222
|
-
- check-jenkins-health.rb
|
223
|
-
- check-jenkins-job-status.rb
|
224
|
-
- check-jenkins.rb
|
225
221
|
- metrics-jenkins-jqs.rb
|
222
|
+
- check-jenkins-job-status.rb
|
223
|
+
- check-jenkins-health.rb
|
224
|
+
- check-jenkins-build-time.rb
|
226
225
|
- metrics-jenkins.rb
|
226
|
+
- check-jenkins.rb
|
227
227
|
extensions: []
|
228
228
|
extra_rdoc_files: []
|
229
229
|
files:
|
@@ -264,7 +264,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
264
264
|
version: '0'
|
265
265
|
requirements: []
|
266
266
|
rubyforge_project:
|
267
|
-
rubygems_version: 2.
|
267
|
+
rubygems_version: 2.5.2.1
|
268
268
|
signing_key:
|
269
269
|
specification_version: 4
|
270
270
|
summary: Sensu plugins for jenkins
|