etcd-tools 0.4.0 → 0.4.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 +8 -8
- data/lib/etcd-tools/mixins/etcd.rb +5 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MDJlOGVkMGJjNTAxMDYyNmIxZjA5Y2M1MTNjMTRjNjM2ODg1MjJkYw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZGYwMGM0MGRlMTg2OWQ3MTFhMWYxOTcyYzYxODI1MmVmNDg2NGMwYQ==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
OGQzOWJlYTU1NmQ4MDgxYzFiYzA5YmFmNTBiNjI4OTdiOWZjNmRjMTM5YjBm
|
10
|
+
ZjBmZDBiZWY3YzA2OTYwYWIxN2Q2MTg3YTliOGVmNjZjZDE4ZDViM2ViNGUy
|
11
|
+
OTI0YmI4ZmE3OTYxMGYyMGUzMGM5OWUyYWZmZTM5OWJkZGM0MmM=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
Njg5OGEyNzIxMzNjNzcyNGNlNGJhMzE2YjYzN2Y2NjdlNjUyNGEzMmE0MTM4
|
14
|
+
NzZmNTNlN2JjYmNmYzYxZTg0ZGQ5NzFmNGQ4MDE0ZDhhNmYxMDIxNTIyMWI0
|
15
|
+
OWIzNzZlM2VlNDE3NmM3YzE1YTFhNjAxZDc2MzU3YmViNjNmMjQ=
|
@@ -72,6 +72,8 @@ module Etcd
|
|
72
72
|
etcd_key = path + '/' + key.to_s
|
73
73
|
if value.class == Hash
|
74
74
|
set_hash(value, etcd_key)
|
75
|
+
elsif value.class == Array
|
76
|
+
set(etcd_key, value: value.to_json)
|
75
77
|
else
|
76
78
|
set(etcd_key, value: value)
|
77
79
|
end
|
@@ -86,12 +88,14 @@ module Etcd
|
|
86
88
|
if get(child.key).directory?
|
87
89
|
h[child.key.split('/').last.to_s] = get_hash child.key
|
88
90
|
else
|
89
|
-
|
91
|
+
value = JSON.parse(child.value) rescue value = child.value
|
92
|
+
h[child.key.split('/').last.to_s] = value
|
90
93
|
end
|
91
94
|
end
|
92
95
|
return Hash[h.sort]
|
93
96
|
rescue Exception => e
|
94
97
|
raise e
|
98
|
+
puts e.backtrace
|
95
99
|
end
|
96
100
|
|
97
101
|
def members
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: etcd-tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Radek 'blufor' Slavicinsky
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-02-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: etcd
|