perus 1.0.2 → 1.0.7
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 +5 -5
- data/lib/perus/options.rb +1 -1
- data/lib/perus/pinger/command.rb +1 -1
- data/lib/perus/pinger/commands/remove_path.rb +1 -1
- data/lib/perus/pinger/commands/run_installed_command.rb +1 -1
- data/lib/perus/pinger/commands/upstart_start.rb +1 -1
- data/lib/perus/pinger/commands/upstart_stop.rb +1 -1
- data/lib/perus/pinger/metrics/running.rb +1 -1
- data/lib/perus/pinger/metrics/temp.rb +1 -1
- data/lib/perus/server/migrations/016_values_use_bigint.rb +12 -4
- data/lib/perus/version.rb +1 -1
- data/perus.gemspec +1 -1
- metadata +10 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: df4ce5229a3b9fd5cbc92f3a9105347d6714c92dc55ddb0f9105cecf77023767
|
4
|
+
data.tar.gz: 8ad4ddd70b9f80542df426b80adf7677ecfe1c7f3256908101bed18d7f3fc0f2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f1ede48efa2ec9903ca2ae2a431d32061c5baec5b8c313895ab17ff0c42b11c2842e86b0c246d7ae86d41d3276049ab95ed6fe36e92bd1a6c1617d633f9caf4f
|
7
|
+
data.tar.gz: 498318d3b3f91988175328c563121e60d49d13108ec7c169cedfd4a50186f62d6e8bcf63a47bbcf904d064b8537b88a2e6a4092e679538316585559b65ffd954
|
data/lib/perus/options.rb
CHANGED
data/lib/perus/pinger/command.rb
CHANGED
@@ -26,7 +26,7 @@ module Perus::Pinger
|
|
26
26
|
|
27
27
|
if restricted
|
28
28
|
allowed = Pinger.options[@command.name.demodulize][@name.to_s]
|
29
|
-
raise "the value passed to #{@name} is not allowed" unless allowed.include?(value)
|
29
|
+
raise "the value, #{value}, passed to #{@name} is not allowed" unless allowed.include?(value)
|
30
30
|
end
|
31
31
|
|
32
32
|
results[name] = value
|
@@ -5,7 +5,7 @@ module Perus::Pinger
|
|
5
5
|
description 'Deletes a file or folder. If "path" is a folder, all files
|
6
6
|
and folders within the folder are deleted as well. Valid
|
7
7
|
values for "path" are contained in the pinger config file.'
|
8
|
-
option :path, restricted:
|
8
|
+
option :path, restricted: false
|
9
9
|
|
10
10
|
def run
|
11
11
|
FileUtils.rm_rf([File.expand_path(options.path)], secure: true)
|
@@ -2,7 +2,7 @@ module Perus::Pinger
|
|
2
2
|
class RunInstalledCommand < Command
|
3
3
|
description 'Run the command specified with "path". Valid values for
|
4
4
|
"path" are contained in the pinger config file.'
|
5
|
-
option :path, restricted:
|
5
|
+
option :path, restricted: false
|
6
6
|
|
7
7
|
def run
|
8
8
|
shell(options.path)
|
@@ -2,7 +2,7 @@ module Perus::Pinger
|
|
2
2
|
class UpstartStart < Command
|
3
3
|
description 'Start the upstart job specified with "job". Valid values
|
4
4
|
for "job" are contained in the pinger config file.'
|
5
|
-
option :job, restricted:
|
5
|
+
option :job, restricted: false
|
6
6
|
|
7
7
|
def run
|
8
8
|
result = shell("sudo start #{options.job}")
|
@@ -2,7 +2,7 @@ module Perus::Pinger
|
|
2
2
|
class UpstartStop < Command
|
3
3
|
description 'Stop the upstart job specified with "job". Valid values
|
4
4
|
for "job" are contained in the pinger config file.'
|
5
|
-
option :job, restricted:
|
5
|
+
option :job, restricted: false
|
6
6
|
|
7
7
|
def run
|
8
8
|
result = shell("sudo stop #{options.job}")
|
@@ -3,7 +3,7 @@ module Perus::Pinger
|
|
3
3
|
description 'Reports "yes" if "process_path" is running, "no"
|
4
4
|
otherwise. Valid values for "process_path" are contained
|
5
5
|
in the pinger config file.'
|
6
|
-
option :process_path, restricted:
|
6
|
+
option :process_path, restricted: false
|
7
7
|
metric!
|
8
8
|
|
9
9
|
def run
|
@@ -1,8 +1,16 @@
|
|
1
1
|
Sequel.migration do
|
2
2
|
up do
|
3
|
-
execute("ALTER TABLE values
|
4
|
-
execute("ALTER TABLE errors
|
5
|
-
execute("ALTER TABLE actions
|
6
|
-
execute("ALTER TABLE active_alerts
|
3
|
+
execute("ALTER TABLE values ALTER COLUMN timestamp TYPE bigint")
|
4
|
+
execute("ALTER TABLE errors ALTER COLUMN timestamp TYPE bigint")
|
5
|
+
execute("ALTER TABLE actions ALTER COLUMN timestamp TYPE bigint")
|
6
|
+
execute("ALTER TABLE active_alerts ALTER COLUMN timestamp TYPE bigint")
|
7
|
+
|
8
|
+
execute("ALTER TABLE values ALTER COLUMN id TYPE bigint")
|
9
|
+
execute("ALTER TABLE metrics ALTER COLUMN id TYPE bigint")
|
10
|
+
execute("ALTER TABLE alerts ALTER COLUMN id TYPE bigint")
|
11
|
+
execute("ALTER TABLE active_alerts ALTER COLUMN id TYPE bigint")
|
12
|
+
|
13
|
+
# If a reset needs to be made due to ID limit
|
14
|
+
# "ALTER SEQUENCE values_id_seq RESTART WITH 1;"
|
7
15
|
end
|
8
16
|
end
|
data/lib/perus/version.rb
CHANGED
data/perus.gemspec
CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
|
|
25
25
|
spec.add_dependency 'concurrent-ruby', '~> 0.8'
|
26
26
|
spec.add_dependency 'faye-websocket', '~> 0.10'
|
27
27
|
spec.add_dependency 'websocket-driver', '>= 0.6.4'
|
28
|
-
spec.add_dependency 'rest-client', '~> 1.
|
28
|
+
spec.add_dependency 'rest-client', '~> 2.1.0'
|
29
29
|
spec.add_dependency 'sinatra', '~> 1.4'
|
30
30
|
spec.add_dependency 'sinatra-contrib', '~> 1.4'
|
31
31
|
spec.add_dependency 'sequel', '~> 4.23'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: perus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Will Cannings
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-08-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -100,14 +100,14 @@ dependencies:
|
|
100
100
|
requirements:
|
101
101
|
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version:
|
103
|
+
version: 2.1.0
|
104
104
|
type: :runtime
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version:
|
110
|
+
version: 2.1.0
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: sinatra
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
@@ -192,7 +192,7 @@ dependencies:
|
|
192
192
|
- - "~>"
|
193
193
|
- !ruby/object:Gem::Version
|
194
194
|
version: '0.10'
|
195
|
-
description:
|
195
|
+
description:
|
196
196
|
email:
|
197
197
|
- me@willcannings.com
|
198
198
|
executables:
|
@@ -333,7 +333,7 @@ homepage: https://github.com/cotag/perus
|
|
333
333
|
licenses:
|
334
334
|
- MIT
|
335
335
|
metadata: {}
|
336
|
-
post_install_message:
|
336
|
+
post_install_message:
|
337
337
|
rdoc_options: []
|
338
338
|
require_paths:
|
339
339
|
- lib
|
@@ -348,9 +348,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
348
348
|
- !ruby/object:Gem::Version
|
349
349
|
version: '0'
|
350
350
|
requirements: []
|
351
|
-
rubyforge_project:
|
352
|
-
rubygems_version: 2.
|
353
|
-
signing_key:
|
351
|
+
rubyforge_project:
|
352
|
+
rubygems_version: 2.7.7
|
353
|
+
signing_key:
|
354
354
|
specification_version: 4
|
355
355
|
summary: Simple system overview server
|
356
356
|
test_files: []
|