elecksee 1.0.18 → 1.0.20
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.md +3 -0
- data/lib/elecksee/lxc_file_config.rb +14 -4
- data/lib/elecksee/version.rb +1 -1
- metadata +2 -2
data/CHANGELOG.md
CHANGED
@@ -7,10 +7,20 @@ class Lxc
|
|
7
7
|
class << self
|
8
8
|
|
9
9
|
def convert_to_hash(thing)
|
10
|
-
|
11
|
-
result =
|
12
|
-
|
13
|
-
|
10
|
+
if(defined?(Chef) && thing.is_a?(Chef::Resource))
|
11
|
+
result = Hash[*(
|
12
|
+
(thing.methods - Chef::Resource.instance_methods).map{ |key|
|
13
|
+
unless(key.to_s.start_with?('_') || thing.send(key).nil?)
|
14
|
+
[key, thing.send(key)]
|
15
|
+
end
|
16
|
+
}.compact.flatten(1)
|
17
|
+
)]
|
18
|
+
else
|
19
|
+
unless(thing.is_a?(Hash))
|
20
|
+
result = defined?(Mash) ? Mash.new : {}
|
21
|
+
thing.to_hash.each do |k,v|
|
22
|
+
result[k] = v.respond_to?(:keys) && v.respond_to?(:values) ? convert_to_hash(v) : v
|
23
|
+
end
|
14
24
|
end
|
15
25
|
end
|
16
26
|
result || thing
|
data/lib/elecksee/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: elecksee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.20
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2014-01-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: mixlib-shellout
|