sensu-plugins-openvpn 1.0.0 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 675df5b4e145ab7a68abe1bb0ec7e432b1b435b2
4
- data.tar.gz: b290649df3a30d37de44040bc4cf1d3d58a1f90a
2
+ SHA256:
3
+ metadata.gz: 8fcb22900ff3c9c87f4eea33e8e15681ccce1d0eda2346bfe279c98580842fff
4
+ data.tar.gz: 6dccb60ce9089193cde708d62dbc9e217372809e943ccdd76827393b47164960
5
5
  SHA512:
6
- metadata.gz: 0e3072945bf6d7f9db70dcb19bb5e60941f0a5d02c75a104b311f92cc04695ca463d36231e7d162b366bd69022d8df6838da7c9c3c5b242380229738c1194f94
7
- data.tar.gz: 8d0898eb296fbdbf9ab025169184668ed8f7a4fa35af56b4a180f22b6d08055435de7cd3577baff0dbb57a31113f940cf806eea091ae6a8249ca30ea6435ec27
6
+ metadata.gz: '0929da09801617fb5df2125a5b3fef7e08b4ba092cd4ee35cd6ee394f46d4fbf06af889569a346d4f7058b3526a1424ee9732d385636e9a29d0133772c221074'
7
+ data.tar.gz: 4869f2b90dce09b8b2cc70419aef27680e11e2024331efae9ef34bbe7219615f1b1918cbc836ae3f7ef02c140ff45ffbde464bc5631d192040671fd0561cb8c7
data/CHANGELOG.md CHANGED
@@ -5,6 +5,21 @@ This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachang
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [2.0.0] 2019-12-16
9
+ ### Security
10
+ - Updated yard development dependency from '~> 0.8.0' to '~> 0.9.20'
11
+
12
+ ### Changed
13
+ - Updated rubocop development dependency from '~> 0.40.0' to '~> 0.50.0'
14
+
15
+ ### Added
16
+ - Travis build automation to generate Sensu Asset tarballs that can be used n conjunction with Sensu provided ruby runtime assets and the Bonsai Asset Index
17
+ - Require latest sensu-plugin for Sensu Go support
18
+
19
+ ### Breaking change
20
+ - Updates minimum required ruby version to 2.3. Drop unsupported ruby versions.
21
+ - Update dependancy on sensu-plugin to 4.0
22
+
8
23
  ## [1.0.0] 2017-07-14
9
24
  ### Added
10
25
  - Testing on Ruby 2.3.0 & 2.4.1
@@ -24,7 +39,8 @@ This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachang
24
39
  ### Added
25
40
  - initial release
26
41
 
27
- [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-openvpn/compare/1.0.1...HEAD
42
+ [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-openvpn/compare/2.0.0...HEAD
43
+ [2.0.0]: https://github.com/sensu-plugins/sensu-plugins-openvpn/compare/1.0.0...2.0.0
28
44
  [1.0.0]: https://github.com/sensu-plugins/sensu-plugins-openvpn/compare/0.0.3...1.0.0
29
45
  [0.0.3]: https://github.com/sensu-plugins/sensu-plugins-openvpn/compare/0.0.2...0.0.3
30
46
  [0.0.2]: https://github.com/sensu-plugins/sensu-plugins-openvpn/compare/0.0.1...0.0.2
data/README.md CHANGED
@@ -1,19 +1,125 @@
1
- ## Sensu-Plugins-openvpn
2
-
1
+ [![Bonsai Asset Badge](https://img.shields.io/badge/Sensu%20OpenVPN%20Plugin-Download%20Me-brightgreen.svg?colorB=89C967&logo=sensu)](https://bonsai.sensu.io/assets/sensu-plugins/sensu-plugins-openvpn)
3
2
  [ ![Build Status](https://travis-ci.org/sensu-plugins/sensu-plugins-openvpn.svg?branch=master)](https://travis-ci.org/sensu-plugins/sensu-plugins-openvpn)
4
3
  [![Gem Version](https://badge.fury.io/rb/sensu-plugins-openvpn.svg)](http://badge.fury.io/rb/sensu-plugins-openvpn)
5
4
  [![Code Climate](https://codeclimate.com/github/sensu-plugins/sensu-plugins-openvpn/badges/gpa.svg)](https://codeclimate.com/github/sensu-plugins/sensu-plugins-openvpn)
6
5
  [![Test Coverage](https://codeclimate.com/github/sensu-plugins/sensu-plugins-openvpn/badges/coverage.svg)](https://codeclimate.com/github/sensu-plugins/sensu-plugins-openvpn)
7
6
  [![Dependency Status](https://gemnasium.com/sensu-plugins/sensu-plugins-openvpn.svg)](https://gemnasium.com/sensu-plugins/sensu-plugins-openvpn)
8
7
 
9
- ## Functionality
8
+ ## Sensu OpenVPN Metrics Plugin
10
9
 
11
- ## Files
12
- * bin/metrics-openvpn.rb
10
+ - [Overview](#overview)
11
+ - [Usage examples](#usage-examples)
12
+ - [Configuration](#configuration)
13
+ - [Sensu Go](#sensu-go)
14
+ - [Asset registration](#asset-registration)
15
+ - [Asset definition](#asset-definition)
16
+ - [Check definition](#check-definition)
17
+ - [Sensu Core](#sensu-core)
18
+ - [Check definition](#check-definition)
19
+ - [Additional information](#additional-information)
20
+ - [Files](#files)
21
+ - [Installation](#installation)
22
+
23
+
24
+ ### Overview
25
+
26
+ This plugin provides native OpenVPN instrumentation for metrics collection of `load-stats` metrics. It is capable of being used with both Sensu Core and Sensu Go.
27
+
28
+ The Sensu assets packaged from this repository are built against the Sensu ruby runtime environment. When using these assets as part of a Sensu Go resource (check, mutator or handler), make sure you include the corresponding Sensu ruby runtime asset in the list of assets needed by the resource. The current ruby-runtime assets can be found [here](https://bonsai.sensu.io/assets/sensu/sensu-ruby-runtime) in the [Bonsai Asset Index](bonsai.sensu.io)
29
+
30
+ ### Usage examples
31
+ ```
32
+ Usage: metrics-openvpn.rb (options)
33
+ -h, --host HOST Host to connect to
34
+ -p, --port PORT Port to connect to
35
+ -r, --prompt PROMPT Initial prompt for OpenVPN admin interface
36
+ -s, --scheme SCHEME Metric naming scheme, text to prepend to metric
37
+ -e, --service SERVICE If more than one openvpn service is running here, name this one to identify it
38
+ -t, --timeout TIMEOUT Connection timeout
39
+ ```
40
+ ### Configuration
41
+
42
+ #### Sensu Go
43
+ ##### Asset registration
44
+
45
+ Assets are the best way to make use of this handler. If you're not using an asset, please consider doing so! If you're using sensuctl 5.13 or later, you can use the following command to add the asset:
46
+
47
+ `sensuctl asset add sensu/sensu-email-handler`
13
48
 
14
- ## Usage
49
+ If you're using an earlier version of sensuctl, you can download the asset definition from [this project's Bonsai Asset Index page](https://bonsai.sensu.io/assets/sensu-plugins/sensu-plugins-openvpn).
15
50
 
51
+ ##### Asset definition
52
+ ```yml
53
+ ---
54
+ type: Asset
55
+ api_version: core/v2
56
+ metadata:
57
+ name: sensu-plugins-openvpn_centos_amd64
58
+ labels:
59
+ annotations:
60
+ io.sensu.bonsai.url: https://bonsai.sensu.io/assets/asachs01/sensu-plugins-openvpn
61
+ io.sensu.bonsai.api_url: https://bonsai.sensu.io/api/v1/assets/asachs01/sensu-plugins-openvpn
62
+ io.sensu.bonsai.tier: Community
63
+ io.sensu.bonsai.version: 1.0.4-pre
64
+ io.sensu.bonsai.namespace: asachs01
65
+ io.sensu.bonsai.name: sensu-plugins-openvpn
66
+ io.sensu.bonsai.tags: experimental, pre-release
67
+ spec:
68
+ url: https://assets.bonsai.sensu.io/1ae7ab5fd0421f1c216d92bd26c3abe7c50d3577/sensu-plugins-openvpn_1.0.4-pre_centos_linux_amd64.tar.gz
69
+ sha512: bc2ab56354ec9fe5ca468c391000bcdc1d8893818561c21cc6bea6e3fde5c405434bf01e867c4de383c5626601c9ee19c8a5c0af87d0b2debc663c93c172f677
70
+ filters:
71
+ - entity.system.os == 'linux'
72
+ - entity.system.arch == 'amd64'
73
+ - entity.system.platform_family == 'rhel'
16
74
  ```
75
+ ##### Check definition
76
+ ```yml
77
+ ---
78
+ type: CheckConfig
79
+ api_version: core/v2
80
+ metadata:
81
+ name: metrics-openvpn
82
+ namespace: default
83
+ spec:
84
+ command: 'metrics-openvpn.rb'
85
+ runtime_assets:
86
+ - sensu-plugins/sensu-plugins-openvpn
87
+ - sensu/sensu-ruby-runtime
88
+ subscriptions:
89
+ - linux
90
+ interval: 10
91
+ timeout: 5
92
+ output_metric_format: graphite_plaintext
93
+ output_metric_handlers:
94
+ - influxdb
95
+ ```
96
+ #### Sensu Core
97
+ ##### Check definition
98
+ ```json
99
+ {
100
+ "checks": {
101
+ "metrics-openvpn": {
102
+ "command": "metrics-openvpn.rb",
103
+ "subscribers": ["openvpn"],
104
+ "interval": 10,
105
+ "refresh": 10,
106
+ "handlers": ["influxdb"]
107
+ }
108
+ }
109
+ }
110
+ ```
111
+ #### Additional information
112
+ This plugin can be configured in several ways. The following denotes the order of precedence for how values for this plugin are defined
113
+
114
+ 1. Values defined locally in `/etc/sensu/conf.d/*.json`
115
+
116
+ 2. Command line options passed via --host and --port
117
+
118
+ 3. Built-in defaults (displayed with --help)
119
+
120
+ ##### Example configuration file
121
+ This plugin can be used with a configuration file living on disk as noted above. See the example below:
122
+ ```json
17
123
  {
18
124
  "openvpn-metrics": {
19
125
  "host": "1.2.3.4",
@@ -23,8 +129,14 @@
23
129
  }
24
130
  ```
25
131
 
132
+ ## Files
133
+ * bin/metrics-openvpn.rb
134
+
26
135
  ## Installation
27
136
 
28
- [Installation and Setup](http://sensu-plugins.io/docs/installation_instructions.html)
137
+ ### Sensu Go
138
+
139
+ See the instructions above for [asset registration](#asset-registration)
29
140
 
30
- ## Notes
141
+ ### Sensu Core
142
+ Install and setup plugins on [Sensu Core](https://docs.sensu.io/sensu-core/latest/installation/installing-plugins/)
@@ -1,7 +1,7 @@
1
1
  module SensuPluginsOpenvpn
2
2
  # This defines the version of the gem
3
3
  module Version
4
- MAJOR = 1
4
+ MAJOR = 2
5
5
  MINOR = 0
6
6
  PATCH = 0
7
7
 
metadata CHANGED
@@ -1,71 +1,77 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sensu-plugins-openvpn
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 2.0.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: 2017-07-14 00:00:00.000000000 Z
11
+ date: 2019-12-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sensu-plugin
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.2'
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '5.0'
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
25
28
  - !ruby/object:Gem::Version
26
29
  version: '1.2'
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '5.0'
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: bundler
29
35
  requirement: !ruby/object:Gem::Requirement
30
36
  requirements:
31
37
  - - "~>"
32
38
  - !ruby/object:Gem::Version
33
- version: '1.7'
39
+ version: '2.0'
34
40
  type: :development
35
41
  prerelease: false
36
42
  version_requirements: !ruby/object:Gem::Requirement
37
43
  requirements:
38
44
  - - "~>"
39
45
  - !ruby/object:Gem::Version
40
- version: '1.7'
46
+ version: '2.0'
41
47
  - !ruby/object:Gem::Dependency
42
48
  name: codeclimate-test-reporter
43
49
  requirement: !ruby/object:Gem::Requirement
44
50
  requirements:
45
51
  - - "~>"
46
52
  - !ruby/object:Gem::Version
47
- version: '0.4'
53
+ version: '1.0'
48
54
  type: :development
49
55
  prerelease: false
50
56
  version_requirements: !ruby/object:Gem::Requirement
51
57
  requirements:
52
58
  - - "~>"
53
59
  - !ruby/object:Gem::Version
54
- version: '0.4'
60
+ version: '1.0'
55
61
  - !ruby/object:Gem::Dependency
56
62
  name: github-markup
57
63
  requirement: !ruby/object:Gem::Requirement
58
64
  requirements:
59
65
  - - "~>"
60
66
  - !ruby/object:Gem::Version
61
- version: '1.3'
67
+ version: '3.0'
62
68
  type: :development
63
69
  prerelease: false
64
70
  version_requirements: !ruby/object:Gem::Requirement
65
71
  requirements:
66
72
  - - "~>"
67
73
  - !ruby/object:Gem::Version
68
- version: '1.3'
74
+ version: '3.0'
69
75
  - !ruby/object:Gem::Dependency
70
76
  name: pry
71
77
  requirement: !ruby/object:Gem::Requirement
@@ -86,14 +92,14 @@ dependencies:
86
92
  requirements:
87
93
  - - "~>"
88
94
  - !ruby/object:Gem::Version
89
- version: '10.0'
95
+ version: '12.3'
90
96
  type: :development
91
97
  prerelease: false
92
98
  version_requirements: !ruby/object:Gem::Requirement
93
99
  requirements:
94
100
  - - "~>"
95
101
  - !ruby/object:Gem::Version
96
- version: '10.0'
102
+ version: '12.3'
97
103
  - !ruby/object:Gem::Dependency
98
104
  name: redcarpet
99
105
  requirement: !ruby/object:Gem::Requirement
@@ -128,28 +134,28 @@ dependencies:
128
134
  requirements:
129
135
  - - "~>"
130
136
  - !ruby/object:Gem::Version
131
- version: 0.40.0
137
+ version: 0.50.0
132
138
  type: :development
133
139
  prerelease: false
134
140
  version_requirements: !ruby/object:Gem::Requirement
135
141
  requirements:
136
142
  - - "~>"
137
143
  - !ruby/object:Gem::Version
138
- version: 0.40.0
144
+ version: 0.50.0
139
145
  - !ruby/object:Gem::Dependency
140
146
  name: yard
141
147
  requirement: !ruby/object:Gem::Requirement
142
148
  requirements:
143
149
  - - "~>"
144
150
  - !ruby/object:Gem::Version
145
- version: '0.8'
151
+ version: 0.9.20
146
152
  type: :development
147
153
  prerelease: false
148
154
  version_requirements: !ruby/object:Gem::Requirement
149
155
  requirements:
150
156
  - - "~>"
151
157
  - !ruby/object:Gem::Version
152
- version: '0.8'
158
+ version: 0.9.20
153
159
  description: |-
154
160
  This plugin provides native OpenVPN instrumentation
155
161
  for metrics collection of `load-stats` metrics.
@@ -183,7 +189,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
183
189
  requirements:
184
190
  - - ">="
185
191
  - !ruby/object:Gem::Version
186
- version: 2.0.0
192
+ version: 2.3.0
187
193
  required_rubygems_version: !ruby/object:Gem::Requirement
188
194
  requirements:
189
195
  - - ">="
@@ -191,7 +197,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
191
197
  version: '0'
192
198
  requirements: []
193
199
  rubyforge_project:
194
- rubygems_version: 2.4.5
200
+ rubygems_version: 2.7.7
195
201
  signing_key:
196
202
  specification_version: 4
197
203
  summary: Sensu plugins for openvpn