outliers 0.1.0 → 0.1.1
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/CHANGELOG.md +4 -0
- data/lib/outliers/cli/evaluate.rb +14 -12
- data/lib/outliers/collection.rb +1 -1
- data/lib/outliers/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: 370c7538e31dc0846ae0de97c21b9eadc6cafe22
|
4
|
+
data.tar.gz: ecb6077e1e2451e3f7d19b58ab0d5ebedf673178
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5ef91692770636f84be52db5fa1989d7d9d3c54bda9fa206b60e63fc1b7186cfc3959c02287af1ae8b575ba6fe8a7f191d9d866bd43c4c15a394174ca485dacd
|
7
|
+
data.tar.gz: 8ab846d7b565ccaf4dfb4afaf377971e058dbc99f5d1fda119c57fe9a1d53a46dd7ca95d60eaa16acfe19ab2db18540b489ab8f1f8b1d8c73bd5edafeef28640
|
data/CHANGELOG.md
CHANGED
@@ -14,12 +14,18 @@ module Outliers
|
|
14
14
|
|
15
15
|
load_credentials
|
16
16
|
|
17
|
+
@options[:parsed_arguments] = parse_arguments
|
18
|
+
|
19
|
+
# Make options available global
|
20
|
+
# Required to read by instance_eval in @run.evaluate
|
21
|
+
@@options = @options
|
22
|
+
|
17
23
|
begin
|
18
|
-
@run.evaluate "
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
24
|
+
@run.evaluate "Running verification provided via CLI." do
|
25
|
+
connect 'cli'
|
26
|
+
resources @@options[:resource], @@options[:target_resources]
|
27
|
+
exclude @@options[:exclude] if @@options[:exclude].any?
|
28
|
+
verify @@options[:verification], @@options[:parsed_arguments]
|
23
29
|
end
|
24
30
|
rescue Outliers::Exceptions::Base => e
|
25
31
|
@logger.error e.message
|
@@ -54,12 +60,8 @@ module Outliers
|
|
54
60
|
|
55
61
|
@run.credentials = { 'cli' => credentials }
|
56
62
|
end
|
57
|
-
|
58
|
-
def target_resources
|
59
|
-
@options[:target_resources]
|
60
|
-
end
|
61
63
|
|
62
|
-
def
|
64
|
+
def parse_arguments
|
63
65
|
arguments = {}
|
64
66
|
|
65
67
|
@options[:arguments].each do |a|
|
@@ -92,8 +94,8 @@ module Outliers
|
|
92
94
|
@options[:provider] = o
|
93
95
|
end
|
94
96
|
|
95
|
-
opts.on("-r", "--resources [RESOURCES]", "Name of
|
96
|
-
@options[:
|
97
|
+
opts.on("-r", "--resources [RESOURCES]", "Name of resource collection to evaluate.") do |o|
|
98
|
+
@options[:resource] = o
|
97
99
|
end
|
98
100
|
|
99
101
|
opts.on("-t", "--target_resources [TARGET_RESOURCES]", "Target resources with key name (can be specified more than once).") do |o|
|
data/lib/outliers/collection.rb
CHANGED
@@ -99,7 +99,7 @@ module Outliers
|
|
99
99
|
@all = all.select {|r| targets.include? r.id }
|
100
100
|
|
101
101
|
unless all.any?
|
102
|
-
raise Outliers::Exceptions::TargetNotFound.new "No '#{targets}'
|
102
|
+
raise Outliers::Exceptions::TargetNotFound.new "No resources found matching one or more of '#{targets}'."
|
103
103
|
end
|
104
104
|
|
105
105
|
@all
|
data/lib/outliers/version.rb
CHANGED