docker-api 1.8.3 → 1.8.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/docker/image.rb +2 -2
- data/lib/docker/version.rb +1 -1
- data/spec/docker/image_spec.rb +3 -0
- data/spec/vcr/Docker_Image/_history/returns_the_history_of_the_Image.yml +12 -12
- data/spec/vcr/Docker_Image/_json/returns_additional_information_about_image_image.yml +12 -12
- data/spec/vcr/Docker_Image/_remove/removes_the_Image.yml +24 -24
- data/spec/vcr/Docker_Image/_tag/tags_the_image_with_the_repo_name.yml +14 -8
- 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: 4322eaf478696f746bbd265cbeafafec0efebfed
|
4
|
+
data.tar.gz: d96d82977b0af43543421b89acc365457159baa9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f95d925f8c175e9809bb3e4db97a91c2b3e2177ce175b56e6fc1b7863900b3efca98364333a6e713f246851182ad84bbd703107e48ab8c8244074c3f7f33435b
|
7
|
+
data.tar.gz: f6620ec718d0bcab618465db873cb51ee1ac190d3705945042ac89b9e50612e3f6eac56a30c710046e58b30efa57da526255922676ffee9b7dfe576af2c880ed
|
data/lib/docker/image.rb
CHANGED
@@ -102,8 +102,8 @@ class Docker::Image < Docker::Base
|
|
102
102
|
else
|
103
103
|
{}
|
104
104
|
end
|
105
|
-
conn.post('/images/create', opts)
|
106
|
-
id =
|
105
|
+
body = conn.post('/images/create', opts)
|
106
|
+
id = Docker::Util.parse_json("[#{body.gsub(/}\s*{/, '},{')}]").last['id']
|
107
107
|
new(conn, 'id' => id, :headers => headers)
|
108
108
|
end
|
109
109
|
|
data/lib/docker/version.rb
CHANGED
data/spec/docker/image_spec.rb
CHANGED
@@ -208,7 +208,10 @@ describe Docker::Image do
|
|
208
208
|
|
209
209
|
it 'sets the id', :vcr do
|
210
210
|
image.should be_a Docker::Image
|
211
|
+
image.id.should match(/\A[a-fA-F0-9]+\Z/)
|
212
|
+
image.id.should_not include('base')
|
211
213
|
image.id.should_not be_nil
|
214
|
+
image.id.should_not be_empty
|
212
215
|
end
|
213
216
|
end
|
214
217
|
end
|
@@ -8,7 +8,7 @@ http_interactions:
|
|
8
8
|
string: ''
|
9
9
|
headers:
|
10
10
|
User-Agent:
|
11
|
-
- Swipely/Docker-API 1.
|
11
|
+
- Swipely/Docker-API 1.8.3
|
12
12
|
Content-Type:
|
13
13
|
- text/plain
|
14
14
|
response:
|
@@ -19,14 +19,14 @@ http_interactions:
|
|
19
19
|
Content-Type:
|
20
20
|
- application/json
|
21
21
|
Date:
|
22
|
-
-
|
22
|
+
- Thu, 27 Feb 2014 21:22:24 GMT
|
23
23
|
Connection:
|
24
24
|
- close
|
25
25
|
Transfer-Encoding:
|
26
26
|
- ''
|
27
27
|
body:
|
28
28
|
encoding: UTF-8
|
29
|
-
string: "{\"status\":\"Pulling repository base\"}{\"status\":\"Pulling image
|
29
|
+
string: "{\"status\":\"Pulling repository base\"}\r\n{\"status\":\"Pulling image
|
30
30
|
(ubuntu-quantl) from base\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
31
31
|
image (ubuntu-quantl) from base, endpoint: https://cdn-registry-1.docker.io/v1/\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
32
32
|
dependent layers\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
@@ -34,16 +34,16 @@ http_interactions:
|
|
34
34
|
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
35
35
|
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}"
|
36
36
|
http_version:
|
37
|
-
recorded_at:
|
37
|
+
recorded_at: Thu, 27 Feb 2014 21:22:24 GMT
|
38
38
|
- request:
|
39
39
|
method: get
|
40
|
-
uri: unix:///var/run/docker.sock/v1.8/images/
|
40
|
+
uri: unix:///var/run/docker.sock/v1.8/images/b750fe79269d/history
|
41
41
|
body:
|
42
42
|
encoding: US-ASCII
|
43
43
|
string: ''
|
44
44
|
headers:
|
45
45
|
User-Agent:
|
46
|
-
- Swipely/Docker-API 1.
|
46
|
+
- Swipely/Docker-API 1.8.3
|
47
47
|
Content-Type:
|
48
48
|
- text/plain
|
49
49
|
response:
|
@@ -51,20 +51,20 @@ http_interactions:
|
|
51
51
|
code: 200
|
52
52
|
message:
|
53
53
|
headers:
|
54
|
+
Content-Type:
|
55
|
+
- application/json
|
54
56
|
Date:
|
55
|
-
-
|
57
|
+
- Thu, 27 Feb 2014 21:22:24 GMT
|
56
58
|
Content-Length:
|
57
|
-
- '
|
58
|
-
Content-Type:
|
59
|
-
- text/plain; charset=utf-8
|
59
|
+
- '309'
|
60
60
|
Connection:
|
61
61
|
- close
|
62
62
|
body:
|
63
63
|
encoding: UTF-8
|
64
64
|
string: |-
|
65
|
-
[{"Created":1364102658,"CreatedBy":"/bin/bash","Id":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc","Size":
|
65
|
+
[{"Created":1364102658,"CreatedBy":"/bin/bash","Id":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc","Size":77,"Tags":["base:latest","base:ubuntu-12.10","base:ubuntu-quantal","base:ubuntu-quantl"]}
|
66
66
|
,{"Created":1364068391,"CreatedBy":"","Id":"27cf784147099545","Size":175306958,"Tags":null}
|
67
67
|
]
|
68
68
|
http_version:
|
69
|
-
recorded_at:
|
69
|
+
recorded_at: Thu, 27 Feb 2014 21:22:24 GMT
|
70
70
|
recorded_with: VCR 2.8.0
|
@@ -8,7 +8,7 @@ http_interactions:
|
|
8
8
|
string: ''
|
9
9
|
headers:
|
10
10
|
User-Agent:
|
11
|
-
- Swipely/Docker-API 1.
|
11
|
+
- Swipely/Docker-API 1.8.3
|
12
12
|
Content-Type:
|
13
13
|
- text/plain
|
14
14
|
response:
|
@@ -19,14 +19,14 @@ http_interactions:
|
|
19
19
|
Content-Type:
|
20
20
|
- application/json
|
21
21
|
Date:
|
22
|
-
-
|
22
|
+
- Thu, 27 Feb 2014 21:22:22 GMT
|
23
23
|
Connection:
|
24
24
|
- close
|
25
25
|
Transfer-Encoding:
|
26
26
|
- ''
|
27
27
|
body:
|
28
28
|
encoding: UTF-8
|
29
|
-
string: "{\"status\":\"Pulling repository base\"}{\"status\":\"Pulling image
|
29
|
+
string: "{\"status\":\"Pulling repository base\"}\r\n{\"status\":\"Pulling image
|
30
30
|
(ubuntu-quantl) from base\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
31
31
|
image (ubuntu-quantl) from base, endpoint: https://cdn-registry-1.docker.io/v1/\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
32
32
|
dependent layers\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
@@ -34,16 +34,16 @@ http_interactions:
|
|
34
34
|
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
35
35
|
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}"
|
36
36
|
http_version:
|
37
|
-
recorded_at:
|
37
|
+
recorded_at: Thu, 27 Feb 2014 21:22:24 GMT
|
38
38
|
- request:
|
39
39
|
method: get
|
40
|
-
uri: unix:///var/run/docker.sock/v1.8/images/
|
40
|
+
uri: unix:///var/run/docker.sock/v1.8/images/b750fe79269d/json
|
41
41
|
body:
|
42
42
|
encoding: US-ASCII
|
43
43
|
string: ''
|
44
44
|
headers:
|
45
45
|
User-Agent:
|
46
|
-
- Swipely/Docker-API 1.
|
46
|
+
- Swipely/Docker-API 1.8.3
|
47
47
|
Content-Type:
|
48
48
|
- text/plain
|
49
49
|
response:
|
@@ -51,17 +51,17 @@ http_interactions:
|
|
51
51
|
code: 200
|
52
52
|
message:
|
53
53
|
headers:
|
54
|
+
Content-Type:
|
55
|
+
- application/json
|
54
56
|
Date:
|
55
|
-
-
|
57
|
+
- Thu, 27 Feb 2014 21:22:24 GMT
|
56
58
|
Content-Length:
|
57
|
-
- '
|
58
|
-
Content-Type:
|
59
|
-
- text/plain; charset=utf-8
|
59
|
+
- '643'
|
60
60
|
Connection:
|
61
61
|
- close
|
62
62
|
body:
|
63
63
|
encoding: UTF-8
|
64
|
-
string: "{\"id\":\"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc\",\"parent\":\"27cf784147099545\",\"created\":\"2013-03-23T22:24:18.818426-07:00\",\"container\":\"3d67245a8d72ecf13f33dffac9f79dcdf70f75acb84d308770391510e0c23ad0\",\"container_config\":{\"Hostname\":\"\",\"Domainname\":\"\",\"User\":\"\",\"Memory\":0,\"MemorySwap\":0,\"CpuShares\":0,\"AttachStdin\":false,\"AttachStdout\":false,\"AttachStderr\":false,\"PortSpecs\":null,\"ExposedPorts\":null,\"Tty\":true,\"OpenStdin\":true,\"StdinOnce\":false,\"Env\":null,\"Cmd\":[\"/bin/bash\"],\"Dns\":null,\"Image\":\"base\",\"Volumes\":null,\"VolumesFrom\":\"\",\"WorkingDir\":\"\",\"Entrypoint\":null,\"NetworkDisabled\":false,\"OnBuild\":null},\"Size\":
|
64
|
+
string: "{\"id\":\"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc\",\"parent\":\"27cf784147099545\",\"created\":\"2013-03-23T22:24:18.818426-07:00\",\"container\":\"3d67245a8d72ecf13f33dffac9f79dcdf70f75acb84d308770391510e0c23ad0\",\"container_config\":{\"Hostname\":\"\",\"Domainname\":\"\",\"User\":\"\",\"Memory\":0,\"MemorySwap\":0,\"CpuShares\":0,\"AttachStdin\":false,\"AttachStdout\":false,\"AttachStderr\":false,\"PortSpecs\":null,\"ExposedPorts\":null,\"Tty\":true,\"OpenStdin\":true,\"StdinOnce\":false,\"Env\":null,\"Cmd\":[\"/bin/bash\"],\"Dns\":null,\"Image\":\"base\",\"Volumes\":null,\"VolumesFrom\":\"\",\"WorkingDir\":\"\",\"Entrypoint\":null,\"NetworkDisabled\":false,\"OnBuild\":null},\"Size\":77}"
|
65
65
|
http_version:
|
66
|
-
recorded_at:
|
66
|
+
recorded_at: Thu, 27 Feb 2014 21:22:24 GMT
|
67
67
|
recorded_with: VCR 2.8.0
|
@@ -8,7 +8,7 @@ http_interactions:
|
|
8
8
|
string: ''
|
9
9
|
headers:
|
10
10
|
User-Agent:
|
11
|
-
- Swipely/Docker-API 1.
|
11
|
+
- Swipely/Docker-API 1.8.4
|
12
12
|
Content-Type:
|
13
13
|
- text/plain
|
14
14
|
response:
|
@@ -19,14 +19,14 @@ http_interactions:
|
|
19
19
|
Content-Type:
|
20
20
|
- application/json
|
21
21
|
Date:
|
22
|
-
-
|
22
|
+
- Fri, 28 Feb 2014 19:13:55 GMT
|
23
23
|
Connection:
|
24
24
|
- close
|
25
25
|
Transfer-Encoding:
|
26
26
|
- ''
|
27
27
|
body:
|
28
28
|
encoding: UTF-8
|
29
|
-
string: "{\"status\":\"Pulling repository base\"}{\"status\":\"Pulling image
|
29
|
+
string: "{\"status\":\"Pulling repository base\"}\r\n{\"status\":\"Pulling image
|
30
30
|
(ubuntu-quantl) from base\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
31
31
|
image (ubuntu-quantl) from base, endpoint: https://cdn-registry-1.docker.io/v1/\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
32
32
|
dependent layers\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
@@ -34,16 +34,16 @@ http_interactions:
|
|
34
34
|
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
35
35
|
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}"
|
36
36
|
http_version:
|
37
|
-
recorded_at:
|
37
|
+
recorded_at: Fri, 28 Feb 2014 19:13:56 GMT
|
38
38
|
- request:
|
39
39
|
method: delete
|
40
|
-
uri: unix:///var/run/docker.sock/v1.8/images/
|
40
|
+
uri: unix:///var/run/docker.sock/v1.8/images/b750fe79269d
|
41
41
|
body:
|
42
42
|
encoding: US-ASCII
|
43
43
|
string: ''
|
44
44
|
headers:
|
45
45
|
User-Agent:
|
46
|
-
- Swipely/Docker-API 1.
|
46
|
+
- Swipely/Docker-API 1.8.4
|
47
47
|
Content-Type:
|
48
48
|
- text/plain
|
49
49
|
response:
|
@@ -51,21 +51,26 @@ http_interactions:
|
|
51
51
|
code: 200
|
52
52
|
message:
|
53
53
|
headers:
|
54
|
+
Content-Type:
|
55
|
+
- application/json
|
54
56
|
Date:
|
55
|
-
-
|
57
|
+
- Fri, 28 Feb 2014 19:13:57 GMT
|
56
58
|
Content-Length:
|
57
|
-
- '
|
58
|
-
Content-Type:
|
59
|
-
- text/plain; charset=utf-8
|
59
|
+
- '246'
|
60
60
|
Connection:
|
61
61
|
- close
|
62
62
|
body:
|
63
63
|
encoding: UTF-8
|
64
64
|
string: |-
|
65
|
-
[{"Untagged":"
|
65
|
+
[{"Untagged":"base:latest"}
|
66
|
+
,{"Untagged":"base:ubuntu-12.10"}
|
67
|
+
,{"Untagged":"base:ubuntu-quantal"}
|
68
|
+
,{"Untagged":"base:ubuntu-quantl"}
|
69
|
+
,{"Deleted":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc"}
|
70
|
+
,{"Deleted":"27cf784147099545"}
|
66
71
|
]
|
67
72
|
http_version:
|
68
|
-
recorded_at:
|
73
|
+
recorded_at: Fri, 28 Feb 2014 19:13:57 GMT
|
69
74
|
- request:
|
70
75
|
method: get
|
71
76
|
uri: unix:///var/run/docker.sock/v1.8/images/json
|
@@ -74,7 +79,7 @@ http_interactions:
|
|
74
79
|
string: ''
|
75
80
|
headers:
|
76
81
|
User-Agent:
|
77
|
-
- Swipely/Docker-API 1.
|
82
|
+
- Swipely/Docker-API 1.8.4
|
78
83
|
Content-Type:
|
79
84
|
- text/plain
|
80
85
|
response:
|
@@ -82,22 +87,17 @@ http_interactions:
|
|
82
87
|
code: 200
|
83
88
|
message:
|
84
89
|
headers:
|
90
|
+
Content-Type:
|
91
|
+
- application/json
|
85
92
|
Date:
|
86
|
-
-
|
93
|
+
- Fri, 28 Feb 2014 19:13:57 GMT
|
87
94
|
Content-Length:
|
88
|
-
- '
|
89
|
-
Content-Type:
|
90
|
-
- text/plain; charset=utf-8
|
95
|
+
- '2'
|
91
96
|
Connection:
|
92
97
|
- close
|
93
98
|
body:
|
94
99
|
encoding: UTF-8
|
95
|
-
string:
|
96
|
-
[{"Created":1392224753,"Id":"dae27da5a73f01eede1699649c42c727651b4311d2ff689810bf22c75c2d2a08","ParentId":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc","RepoTags":["\u003cnone\u003e:\u003cnone\u003e"],"Size":7,"VirtualSize":350613950}
|
97
|
-
,{"Created":1392224748,"Id":"291b17ca54f04278c166b1313f9ec211fa27596a6f5a20855fcd8739b8f26116","ParentId":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc","RepoTags":["\u003cnone\u003e:\u003cnone\u003e"],"Size":7,"VirtualSize":350613950}
|
98
|
-
,{"Created":1392224744,"Id":"328de6c59bef1db641600ea40668bbd57f6966a146bebe9640030dea13d0008c","ParentId":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc","RepoTags":["\u003cnone\u003e:\u003cnone\u003e"],"Size":7,"VirtualSize":350613950}
|
99
|
-
,{"Created":1364102658,"Id":"b750fe79269d2ec9a3c593ef05b4332b1d1a02a62b4accb2c21d589ff2f5f2dc","ParentId":"27cf784147099545","RepoTags":["base2:latest"],"Size":175306985,"VirtualSize":350613943}
|
100
|
-
]
|
100
|
+
string: "[]"
|
101
101
|
http_version:
|
102
|
-
recorded_at:
|
102
|
+
recorded_at: Fri, 28 Feb 2014 19:13:57 GMT
|
103
103
|
recorded_with: VCR 2.8.0
|
@@ -8,7 +8,7 @@ http_interactions:
|
|
8
8
|
string: ''
|
9
9
|
headers:
|
10
10
|
User-Agent:
|
11
|
-
- Swipely/Docker-API 1.8.
|
11
|
+
- Swipely/Docker-API 1.8.4
|
12
12
|
Content-Type:
|
13
13
|
- text/plain
|
14
14
|
response:
|
@@ -19,25 +19,31 @@ http_interactions:
|
|
19
19
|
Content-Type:
|
20
20
|
- application/json
|
21
21
|
Date:
|
22
|
-
-
|
22
|
+
- Fri, 28 Feb 2014 19:11:13 GMT
|
23
23
|
Connection:
|
24
24
|
- close
|
25
25
|
Transfer-Encoding:
|
26
26
|
- ''
|
27
27
|
body:
|
28
28
|
encoding: UTF-8
|
29
|
-
string: ""
|
29
|
+
string: "{\"status\":\"Pulling repository base\"}\r\n{\"status\":\"Pulling image
|
30
|
+
(ubuntu-quantl) from base\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
31
|
+
image (ubuntu-quantl) from base, endpoint: https://cdn-registry-1.docker.io/v1/\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Pulling
|
32
|
+
dependent layers\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
33
|
+
complete\",\"progressDetail\":{},\"id\":\"27cf78414709\"}{\"status\":\"Download
|
34
|
+
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}{\"status\":\"Download
|
35
|
+
complete\",\"progressDetail\":{},\"id\":\"b750fe79269d\"}"
|
30
36
|
http_version:
|
31
|
-
recorded_at:
|
37
|
+
recorded_at: Fri, 28 Feb 2014 19:11:14 GMT
|
32
38
|
- request:
|
33
39
|
method: post
|
34
|
-
uri: unix:///var/run/docker.sock/v1.8/images/
|
40
|
+
uri: unix:///var/run/docker.sock/v1.8/images/b750fe79269d/tag?force=true&repo=base2
|
35
41
|
body:
|
36
42
|
encoding: US-ASCII
|
37
43
|
string: ''
|
38
44
|
headers:
|
39
45
|
User-Agent:
|
40
|
-
- Swipely/Docker-API 1.8.
|
46
|
+
- Swipely/Docker-API 1.8.4
|
41
47
|
Content-Type:
|
42
48
|
- text/plain
|
43
49
|
response:
|
@@ -46,7 +52,7 @@ http_interactions:
|
|
46
52
|
message:
|
47
53
|
headers:
|
48
54
|
Date:
|
49
|
-
-
|
55
|
+
- Fri, 28 Feb 2014 19:11:14 GMT
|
50
56
|
Content-Length:
|
51
57
|
- '0'
|
52
58
|
Content-Type:
|
@@ -57,5 +63,5 @@ http_interactions:
|
|
57
63
|
encoding: UTF-8
|
58
64
|
string: ''
|
59
65
|
http_version:
|
60
|
-
recorded_at:
|
66
|
+
recorded_at: Fri, 28 Feb 2014 19:11:14 GMT
|
61
67
|
recorded_with: VCR 2.8.0
|
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.8.
|
4
|
+
version: 1.8.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Swipely, Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-02-
|
11
|
+
date: 2014-02-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: excon
|