docker_toolkit 0.1.24 → 0.1.25
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/bin/locker.rb +3 -4
- data/lib/docker_toolkit/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 44fc48c8b8bf21989b9be9bb59601c1f53a81db9c33bb1948f80c6b9583b77f6
|
4
|
+
data.tar.gz: c6f049c3a6dbc2a550608b1b82d1446a83c9edfff9b0a603e7c7a53b74ce3869
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0604dac84255d0d23836b7d9dac8687fe462f88948b6434de96febc0dd098c045bba1a1c7a2accff90a10c9fd6f832b7c1dbe3fbeaca4d58764c2825d2994a62
|
7
|
+
data.tar.gz: 63209b9d5b7cd31a5c03cce3e946ff0596dd1c796d5684f189ec5c1d04280ae700888713d59d65ab7f41bfa00d4d1f212c886c5a74b5a364257df59655bbbbe1
|
data/Gemfile.lock
CHANGED
data/bin/locker.rb
CHANGED
@@ -2,10 +2,9 @@
|
|
2
2
|
|
3
3
|
require 'optparse'
|
4
4
|
require 'diplomat'
|
5
|
-
require 'json'
|
6
5
|
|
7
6
|
@opts = {
|
8
|
-
url: 'http://localhost:
|
7
|
+
url: 'http://localhost:8500',
|
9
8
|
timeout: 10,
|
10
9
|
ttl: 30*60,
|
11
10
|
}
|
@@ -40,8 +39,8 @@ parser.parse!
|
|
40
39
|
|
41
40
|
|
42
41
|
def lock session, locker, timeout
|
43
|
-
Timeout::timeout(timeout) do
|
44
|
-
return Diplomat::Lock.wait_to_acquire("
|
42
|
+
Timeout::timeout(timeout) do
|
43
|
+
return Diplomat::Lock.wait_to_acquire("resource/#{locker[:resource]}/lock", session, locker.to_json, 10)
|
45
44
|
end
|
46
45
|
|
47
46
|
rescue Timeout::Error => e
|