docker-api 1.21.0 → 1.21.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.cane +1 -1
- data/lib/docker/connection.rb +15 -11
- data/lib/docker/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c3b954af22c1f99df2d9c36fdfc54411ace8e434
|
4
|
+
data.tar.gz: 5b8b371ba9160fea4c186c398edf4254fc28f97f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9c04fcb8a4379637be10ad3a5b5cbf3e12b683daad49a261fc847815a8dda8674a4a5d1abdcc6267433415ed2d6661d831df29e83374264878fb5e62c6adf401
|
7
|
+
data.tar.gz: 3c3aa39c4368253d522e10d8c6619b98d5de008bec64222beef957f936dcd917a513dcb29b53047a6d38385f7dd40ca5b474b1d5a8b7e59d7be72e9732e2e28a
|
data/.cane
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
--abc-max
|
1
|
+
--abc-max 17
|
2
2
|
--style-measure 100
|
data/lib/docker/connection.rb
CHANGED
@@ -36,24 +36,28 @@ class Docker::Connection
|
|
36
36
|
# Send a request to the server with the `
|
37
37
|
def request(*args, &block)
|
38
38
|
request = compile_request_params(*args, &block)
|
39
|
-
|
40
|
-
Docker.logger.debug(
|
41
|
-
[request[:method], request[:path], request[:query], request[:body]]
|
42
|
-
)
|
43
|
-
end
|
39
|
+
log_request(request)
|
44
40
|
resource.request(request).body
|
45
41
|
rescue Excon::Errors::BadRequest => ex
|
46
|
-
raise ClientError, ex.
|
42
|
+
raise ClientError, ex.response.body
|
47
43
|
rescue Excon::Errors::Unauthorized => ex
|
48
|
-
raise UnauthorizedError, ex.
|
44
|
+
raise UnauthorizedError, ex.response.body
|
49
45
|
rescue Excon::Errors::NotFound => ex
|
50
|
-
raise NotFoundError, ex.
|
46
|
+
raise NotFoundError, ex.response.body
|
51
47
|
rescue Excon::Errors::Conflict => ex
|
52
|
-
raise ConflictError, ex.
|
48
|
+
raise ConflictError, ex.response.body
|
53
49
|
rescue Excon::Errors::InternalServerError => ex
|
54
|
-
raise ServerError, ex.response.
|
50
|
+
raise ServerError, ex.response.body
|
55
51
|
rescue Excon::Errors::Timeout => ex
|
56
|
-
raise TimeoutError, ex.
|
52
|
+
raise TimeoutError, ex.response.body
|
53
|
+
end
|
54
|
+
|
55
|
+
def log_request(request)
|
56
|
+
if Docker.logger
|
57
|
+
Docker.logger.debug(
|
58
|
+
[request[:method], request[:path], request[:query], request[:body]]
|
59
|
+
)
|
60
|
+
end
|
57
61
|
end
|
58
62
|
|
59
63
|
# Delegate all HTTP methods to the #request.
|
data/lib/docker/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: docker-api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.21.
|
4
|
+
version: 1.21.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Swipely, Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-04-
|
11
|
+
date: 2015-04-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: excon
|