percheron 0.7.5 → 0.7.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/percheron/docker_connection.rb +10 -9
- data/lib/percheron/formatters/stack/table.rb +10 -12
- data/lib/percheron/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: ca4e159e1d216215067cbfa7373ae6dbda91fd85
|
4
|
+
data.tar.gz: c8ce94ce02c64514de86526cdc5447912b6acac0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 84e0e88ff4a08b0af7e009b1c67d2b2f19755d063be8e0b81308f4ae174a238d8ce3fb645d93b47215a688ae6121c3666a6b263e9d24976b26b22e1aae36ca59
|
7
|
+
data.tar.gz: ed372015a2a72aec541b29f5263e053eab8c3e00a0d8dbe69456e9e991d56ec16a84a0a265a49ee80cc8e0b2a06eb074b56f9eb1df7f2595ca27f52b68f3fca0
|
@@ -39,15 +39,16 @@ module Percheron
|
|
39
39
|
end
|
40
40
|
|
41
41
|
def extra_docker_opts
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
42
|
+
return {} unless cert_path
|
43
|
+
{
|
44
|
+
client_cert: cert_path_for('cert.pem'),
|
45
|
+
client_key: cert_path_for('key.pem'),
|
46
|
+
ssl_ca_file: cert_path_for('ca.pem')
|
47
|
+
}
|
48
|
+
end
|
49
|
+
|
50
|
+
def cert_path_for(file)
|
51
|
+
File.join(cert_path, file)
|
51
52
|
end
|
52
53
|
|
53
54
|
end
|
@@ -35,24 +35,22 @@ module Percheron
|
|
35
35
|
end
|
36
36
|
|
37
37
|
def rows
|
38
|
-
|
39
|
-
queue_jobs(resp)
|
38
|
+
queue_jobs
|
40
39
|
process_queue!
|
41
|
-
sort_rows(resp)
|
42
40
|
end
|
43
41
|
|
44
|
-
def queue_jobs
|
45
|
-
stack.containers.map
|
46
|
-
queue << Thread.new { resp[Time.now.to_f] = row_for(container) }
|
47
|
-
end
|
42
|
+
def queue_jobs
|
43
|
+
stack.containers.map { |_, container| queue << row_for(container) }
|
48
44
|
end
|
49
45
|
|
50
46
|
def process_queue!
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
47
|
+
resp = []
|
48
|
+
4.times.map do
|
49
|
+
Thread.new do
|
50
|
+
queue.size.times { resp << queue.pop(true) }
|
51
|
+
end
|
52
|
+
end.map(&:join)
|
53
|
+
resp
|
56
54
|
end
|
57
55
|
|
58
56
|
def row_for(container)
|
data/lib/percheron/version.rb
CHANGED